Skip to content
This repository has been archived by the owner on Jun 11, 2022. It is now read-only.
/ logging Public archive

A logging library that doesn't suck.

License

Notifications You must be signed in to change notification settings

unional/logging

Repository files navigation

@unional/logging

Greenkeeper badge

NPM version NPM downloads

Circle CI Travis CI Codecov Coveralls Status

Visual Studio Code Wallaby.js

Important message

This library is deprecated in favor of standard-log.

Overview

A logging library that doesn't suck.

This library was based on aurelia-logging. In 1.0, the coupling is mostly eliminated and the only thing shared is the logLevel and the general design.

You can use any of the following appender with this library:

Usage

import { getLogger } from '@unional/logging'

const log = getLogger('mylogger')

log.error(...)
log.warn(...)
log.info(...)
log.debug(...)

log.onError(log => log(getLogMessageThatIsTimeConsumingToCreate()))
log.onWarn(...)
log.onInfo(...)
log.onDebug(...)

// or
log.onError(() => getLogMessageThatIsTimeConsumingToCreate())

function getLogMessageThatIsTimeConsumingToCreate() {
  ...
}

About

A logging library that doesn't suck.

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published

Contributors 3

  •  
  •  
  •