UNPKG

@tolokoban/tgd

Version:

ToloGameDev library for WebGL2

31 lines 1.09 kB
export type TgdConsoleItem = Partial<TgdConsoleStyle> & { text: string; }; export interface TgdConsoleStyle { color: string; background: string; bold: boolean; } export declare class TgdConsole { /** * Return a function that will log only if a value has changed. */ static memo(defaultLogger?: (out: TgdConsole) => void): (value: unknown, logger?: (out: TgdConsole) => void) => void; static log(...items: (TgdConsoleItem | string)[]): void; static info(...items: (TgdConsoleItem | string)[]): void; static debug(...items: (TgdConsoleItem | string)[]): void; static warn(...items: (TgdConsoleItem | string)[]): void; static error(...items: (TgdConsoleItem | string)[]): void; private readonly items; constructor(...items: (TgdConsoleItem | string)[]); clear(): void; add(text?: string, { color, background, bold }?: Partial<TgdConsoleStyle>): this; nl(): this; log(): void; info(): void; debug(): void; warn(): void; error(): void; private get args(); } //# sourceMappingURL=console.d.ts.map