master
David Kebler 2019-01-25 12:36:57 -08:00
parent 7f23316c4e
commit c244b470f3
2 changed files with 23 additions and 4 deletions

19
example/example.js Normal file
View File

@ -0,0 +1,19 @@
import logger from '../src/logger'
let log = {}
class LOGTEST {
constructor(opts) {
log = logger({
name: 'test',
id: opts.id,
file: 'example/example.js',
class: 'LOGTEST'
})
}
}
let test = new LOGTEST({id:'process-test1'})
log.info({test:'filter', msg:'this is a logged message'})
log.fatal('this is a fatal logged message')

View File

@ -1,6 +1,6 @@
{
"name": "@uci/logger",
"version": "0.0.6",
"version": "0.0.7",
"description": "Parent Logger for all UCI modules",
"main": "src/logger",
"scripts": {
@ -27,16 +27,16 @@
},
"homepage": "https://github.com/uCOMmandIt/uci-changeme#readme",
"dependencies": {
"pino": "^5.11.0",
"pino": "^5.11.1",
"pino-pretty": "^2.5.0"
},
"devDependencies": {
"chai": "^4.2.0",
"chai-as-promised": "^7.1.1",
"codecov": "^3.1.0",
"esm": "^3.0.84",
"esm": "^3.1.2",
"istanbul": "^0.4.5",
"mocha": "^5.2.0",
"nodemon": "^1.18.7"
"nodemon": "^1.18.9"
}
}