Skip to content

reporter

Reset state at the start of each watch build cycle.

k._reset

function

Reset to initial state (used in tests).

k.error

function

Log an error message. In console mode: prints via console.error. In dashboard mode: stored in state and shown in the error section.

k.getState

function

Expose state for testing / introspection.

k.log

function

Log an informational message. In console mode: prints via console.log. In dashboard mode: no-op (file names in status bar serve this purpose).

k.render

function

Force a full redraw of the dashboard. Called by watch.js after processSheet resolves.

k.reportPug

function

Record the result of a pug render pass.

  • name - string -

    — filename (e.g. 'sheet.pug')

  • ok - boolean -

    — true if render succeeded

  • sourceFile - string|null -

    — project-relative path of the erroring file

k.reportSCSS

function

Record the result of a SCSS render pass.

  • name - string -

    — filename (e.g. 'sheet.scss')

  • ok - boolean -

    — true if render succeeded

  • sourceFile - string|null -

    — project-relative path of the erroring file

k.reportTemplate

function

Record the result of template rendering (sheet.json / translation.json).

  • ok - boolean -
    undefined

k.setMode

function

Switch output mode. In dashboard mode, stdout TTY is required — falls back to console if not a TTY.

  • mode - 'console'|'dashboard' -
    undefined

k.setProjectName

function

Override the project name shown in the dashboard header.

Released under the MIT License