1.2.0 • Published 1 day ago

@uma/logger v1.2.0

Weekly downloads
-
License
AGPL-3.0-or-later
Repository
github
Last release
1 day ago

@uma/logger

@uma/logger is a specialized logger package optimized for minimal dependencies, ensuring compatibility and ease of integration.

Installing the package

yarn add @uma/logger

Importing the package

The Logger directory contains helpers and factories for logging with Winston. To get the default logger:

const { Logger } = require("@uma/logger")

// You can also log directly using the winston logger.
Logger.debug({
  at: "createPriceFeed",
  message: "Creating CryptoWatchPriceFeed",
  otherParam: 5,
})

Helpers

There are two helper files that are available in logger:

  • delay.js: simple file containing a function to "sleep".