0.1.0 • Published 6 years ago
@febbyjs/logger v0.1.0
Table of Contents
log
To log user text as json object
Parameters
message
log texttype
type of log. ex: log,error,info,warning
Examples
logger.log('hello world', 'log');
//log output
{ type: 'log', message: 'hello world' }
error
To log error text with red color
Parameters
message
log text
Examples
logger.error('hello world');
success
To log success text with green color
Parameters
message
log text
Examples
logger.success('hello world');
info
To log info text with blue color
Parameters
message
log text
Examples
logger.info('hello world');
warning
To log a warning with yellow color
Parameters
message
log text
Examples
logger.warning('hello world');
customLog
To log text with given rgb color code or color name
Parameters
message
log textcolor
color black, red, green, yellow, blue, magenta, cyan, white, gray ("bright black"), redBright, greenBright, yellowBright, blueBright, magentaBright, yanBright, whiteBright
Examples
logger.customLog('hello world','magentaBright');
0.1.0
6 years ago