2020-03-29 00:43:52 +01:00
|
|
|
import chalk from 'next/dist/compiled/chalk'
|
2019-04-09 17:52:03 +02:00
|
|
|
|
|
|
|
const prefixes = {
|
2020-04-29 10:49:28 +02:00
|
|
|
wait: chalk.cyan('wait') + ' -',
|
|
|
|
error: chalk.red('error') + ' -',
|
|
|
|
warn: chalk.yellow('warn') + ' -',
|
|
|
|
ready: chalk.green('ready') + ' -',
|
|
|
|
info: chalk.cyan('info') + ' -',
|
|
|
|
event: chalk.magenta('event') + ' -',
|
2019-04-09 17:52:03 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
export function wait(...message: string[]) {
|
|
|
|
console.log(prefixes.wait, ...message)
|
|
|
|
}
|
|
|
|
|
|
|
|
export function error(...message: string[]) {
|
|
|
|
console.log(prefixes.error, ...message)
|
|
|
|
}
|
|
|
|
|
|
|
|
export function warn(...message: string[]) {
|
|
|
|
console.log(prefixes.warn, ...message)
|
|
|
|
}
|
|
|
|
|
|
|
|
export function ready(...message: string[]) {
|
|
|
|
console.log(prefixes.ready, ...message)
|
|
|
|
}
|
|
|
|
|
|
|
|
export function info(...message: string[]) {
|
|
|
|
console.log(prefixes.info, ...message)
|
|
|
|
}
|
|
|
|
|
|
|
|
export function event(...message: string[]) {
|
|
|
|
console.log(prefixes.event, ...message)
|
|
|
|
}
|