codigo0/backend/node_modules/triple-beam
planetazuzu 0201f16cf4
Some checks are pending
Auto Deploy to Server / deploy (push) Waiting to run
Update lab configuration 2026-03-22
2026-03-22 22:50:29 +01:00
..
.nyc_output Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00
config Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00
CHANGELOG.md Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00
index.js Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00
LICENSE Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00
package.json Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00
README.md Update lab configuration 2026-03-22 2026-03-22 22:50:29 +01:00

triple-beam

Definitions of levels for logging purposes & shareable Symbol constants.

Usage

const { LEVEL } = require('triple-beam');
const colors = require('colors/safe');

const info = {
  [LEVEL]: 'error',
  level: 'error',
  message: 'hey a logging message!'
};

// Colorize your log level!
info.level = colors.green(info.level);

// And still have an unmutated copy of your level!
console.log(info.level === 'error');  // false
console.log(info[LEVEL] === 'error'); // true

Tests

Tests are written with mocha, assume, and nyc. They can be run with npm:

npm test
LICENSE: MIT
AUTHOR: Charlie Robbins