@bondsports/js-logger
TypeScript icon, indicating that this package has built-in type declarations

2.0.1 • Public • Published

js logger

Javascript and typescript logger for Bond-Sports based on pino.

Usage

import jsLogger from '@bondsports/js-logger';

const logger = jsLogger();

logger.info('hello world');

logger.error({hello: 'world'});

for more detailed usage check the pino documentation.

Configuration

name type default value description
enabled boolean true enables logging
level string 'info' one of the supported level or silent to disable logging
prettyPrint boolean false pretty print for developing purposes
redact array undefined array of paths in object to be redacted from the log
destination number / string 1 The stream to send the log to, or file
base object {pid: process.pid, hostname: os.hostname} Key-value object added as child logger to each log line

Readme

Keywords

none

Package Sidebar

Install

npm i @bondsports/js-logger

Weekly Downloads

349

Version

2.0.1

License

ISC

Unpacked Size

6.51 kB

Total Files

6

Last publish

Collaborators

  • tetrobond
  • dan.spinosa--bondsports.co
  • gittyp
  • ido.naveh.bondsports
  • noam.benzeev
  • barak_matityahu
  • jbknickerbocker