How to use the enableColor function from npmlog
Find comprehensive JavaScript npmlog.enableColor code examples handpicked from public code repositorys.
GitHub: Mondego/pyreco
![Mondego profile picture](/Mondego.png?size=40)
230 231 232 233 234 235 236 237 238
* {Stream} Default: `process.stderr` The stream where output is written. ## log.enableColor() Force colors to be used on all messages, regardless of the output stream.
+ 9 other calls in file
GitHub: punkeel/node
![punkeel profile picture](/punkeel.png?size=40)
39 40 41 42 43 44 45 46 47 48
log.level = config.get('loglevel') log.heading = config.get('heading') || 'npm' if (enableColorStderr) log.enableColor() else log.disableColor() if (config.get('unicode'))
GitHub: NewsUKArchive/dextrose
![NewsUKArchive profile picture](/NewsUKArchive.png?size=40)
0 1 2 3 4 5 6 7 8 9
const log = require('npmlog'); const setupLogger = (logLevel) => { log.level = logLevel || 'info'; log.stream = process.stdout; log.enableColor(); log.info('Dextrose Logger', `Log level is ${log.level}`); }; export default {
npmlog.verbose is the most popular function in npmlog (7425 examples)