Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

nhsuk-bunyan-logger

Package Overview
Dependencies
Maintainers
4
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nhsuk-bunyan-logger

Facade over bunyan logger.

  • 1.13.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
4
Created
Source

NHSUK Bunyan logger

GitHub Release npm version Greenkeeper badge Build Status Coverage Status Known Vulnerabilities

A little library to ease the sharing of the setup of the bunyan logger.

An instance of a bunyan logger is created via the constructor-api and returned.

Install

  • A specific release version (recommended). e.g via yarn: yarn install git://github.com/nhsuk/bunyan-logger.git#x.x.x
  • The latest version (not recommended). e.g. via npm: npm install nhsuk/bunyan-logger
  • Any of the other ways to install an npm package

Usage

const log = require('nhsuk-bunyan-logger')('LOGGER-NAME');

log.METHOD('message goes here');

Where LOGGER-NAME is the name you want for the logger. Where METHOD is any of the supported Bunyan logger methods. Check out the Bunyan documentation for additional information on the API.

Environment Variables

A number of environment variables are used, as detailed below.

VariableDescriptionDefault
NODE_ENVNode environmentdevelopment
LOG_LEVELNumeric log levelDepends on NODE_ENV

A note on LOG_LEVEL - there are default values set depending on the environment. However, if LOG_LEVEL is set this value will override any defaults there might be.

FAQs

Package last updated on 30 Sep 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc