Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including @offirmo/practical-logger-interface with all npm packages installed. Try it out:

var practicalLoggerInterface = require("@offirmo/practical-logger-interface")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

@offirmo/practical-logger-interface v1.1.1

TypeScript types for Offirmo’s practical logger (no code)

Offirmo’s practical logger - TypeScript interfaces
Offirmo’s quality seal

npm badge dependencies badge bundle size badge license badge maintenance status badge

This is an internal component of Offirmo’s practical logger.

  • declares only TypeScript types/interfaces
  • No code, 0 bytes = will do nothing to your bundle size.
  • TODO explain the interface pattern


This is most likely not what you are looking for!

See the actual implementations of those interfaces:


A logger will have the following interface:

  • setLevel(level: LogLevel): void
  • getLevel(): LogLevel
  • addCommonDetails(hash: Readonly<{ [k: string]: any }>): void
  • Log primitives: (mirroring the log levels)
    • fatal(message?: string, details?: Readonly<{ [k: string]: any }>): void
    • emerg(…) idem
    • alert(…) idem
    • crit(…) idem
    • error(…) idem
    • warning(…), warn(…) idem
    • notice(…) idem
    • info(…) idem
    • verbose(…) idem
    • log(…) idem
    • debug(…) idem
    • trace(…) idem
    • silly(…) idem
  • those functions may not do anything:
    • group(groupTitle?: string): void
    • groupCollapsed(groupTitle?: string): void
    • groupEnd(): void


Other loggers:

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free