https://github.com/aliencreations/node-logger
Simple logging wrapper for Pinoo
https://github.com/aliencreations/node-logger
Last synced: 9 months ago
JSON representation
Simple logging wrapper for Pinoo
- Host: GitHub
- URL: https://github.com/aliencreations/node-logger
- Owner: AlienCreations
- Created: 2020-11-06T12:46:11.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2020-11-06T13:49:19.000Z (about 5 years ago)
- Last Synced: 2025-05-09T00:12:49.918Z (9 months ago)
- Language: JavaScript
- Size: 38.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# node-logger
Simple NodeJS logger using Pino.
## Install
```
$ yarn add @aliencreations/node-logger
```
## Usage
Please refer to [the pino documentation](http://getpino.io/#/docs/api?id=options) for the `optionalPinoConfig`
referenced below.
```js
const applicationMetaData = {
appName : config.appName,
someOtherMeta : 'goes here'
};
const optionalPinoConfig = {
redact : ['key', 'path.to.key', 'stuff.thats[*].secret']
};
const logger = require('@aliencreations/node-logger')(applicationMetaData, optionalPinoConfig);
logger.info('some log here');
```
---
## Changelog
##### 1.0.0
- Initial commit.