A Console that emits logs with date and time
See the documentation: /docs
Instalation:
bash: npm i console-ltUse:
const consoleLT = require('console-lt')
consoleLT.log('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [LOG]: Hello Wolrd
consoleLT.info('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [INFO]: Hello Wolrd
consoleLT.warn('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [WARN]: Hello Wolrd
consoleLT.error('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [ERROR]: Hello WolrdThe default console global will be overwriten. So you can use global console to log with date and time:
require('console-lt')
console.log('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [LOG]: Hello Wolrd
console.info('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [INFO]: Hello Wolrd
console.warn('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [WARN]: Hello Wolrd
console.error('Hello Wolrd') //Output: 2020-02-13 14:01:23.234 [ERROR]: Hello WolrdLast update: 13/02/2020
Generated using TypeDoc