🚀 DAY 5 OF LAUNCH WEEK:Introducing Webhook Events for Alert Changes.Learn more →
Socket
Book a DemoInstallSign in
Socket

@fiquu/template

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@fiquu/template

fiquu project template.

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

@fiquu/logger

Simple console logger based on Winston.

It's really just a preconfigured instance of a Winston Logger.

Instalation

npm i @fiquu/logger

Usage

Let's assume you run you app with:

$ LOG_LEVEL=info node index.js

Then, the logger will log anything that has lower priority than the LOG_LEVEL env variable:

./some/module.ts:

import { createLogger } from '@fiquu/logger';

const log: FixedLogger = createLogger('My App Module');

log.debug('This is not necessary on production.'); // Will not log
log.info('This is very informational.');
log.warn('Beware! You\'re about to do a thing.');
log.error('IT FAILED!');
log.error('IT FAILED! SEE DETAILS:', {
  extra: 'Yeah, it was bad...',
  error
});

Read more about Winston's log levels to know what will be logged depending on your LOG_LEVEL env variable.

API Docs

Please visit https://fiquu.github.io/logger/

Keywords

template

FAQs

Package last updated on 25 Feb 2020

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