Skip to content

@graphty/graphty-element / logging / ConsoleSinkOptions

Interface: ConsoleSinkOptions ​

Defined in: graphty-element/src/logging/sinks/ConsoleSink.ts:8

Options for the console sink.

Properties ​

colors? ​

optional colors?: boolean

Defined in: graphty-element/src/logging/sinks/ConsoleSink.ts:19

Let the browser tint each line by its severity.

On means each record goes to the console method that matches its level, and a browser paints console.error red and console.warn yellow. Off means every record goes to console.log, which is painted like any other output -- what a developer wants when the page's own red lines are the ones they are looking for.


formatter? ​

optional formatter?: (record) => string

Defined in: graphty-element/src/logging/sinks/ConsoleSink.ts:10

Render each record differently from the element's own line.

Parameters ​

record ​

LogRecord

Returns ​

string