nlu
Version:
Use this package to link your projects together for local development.
20 lines (15 loc) • 631 B
text/typescript
;
import chalk from 'chalk';
const debugging = process.argv.indexOf('--debug') > 2;
export const log = {
info: console.log.bind(console, chalk.gray('[nlu/info]')),
good: console.log.bind(console, chalk.cyan('[nlu/info]')),
veryGood: console.log.bind(console, chalk.green('[nlu/info]')),
warning: console.log.bind(console, chalk.yellow.bold('[nlu/warn]')),
warn: console.log.bind(console, chalk.yellow.bold('[nlu/warn]')),
error: console.log.bind(console, chalk.magenta('[nlu/error]')),
debug: function (...args: any[]) {
debugging && console.error.apply(console, args);
}
};
export default log;