UNPKG

js-randomness-predictor

Version:
24 lines (23 loc) 630 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); function redText(text) { return `\x1b[31m${text}\x1b[0m`; } function yellowText(s) { return `\x1b[33m${s}\x1b[0m`; } class Logger { static info(...messages) { console.info(`[INFO] ${messages.join(" ")}`); } static log(...messages) { console.log(`[LOG] ${messages.join(" ")}`); } static warn(...messages) { console.warn(yellowText(`[WARN] ${messages.join(" ")}`)); } static error(...messages) { console.error(redText(`[ERROR] ${messages.join(" ")}`)); } } exports.default = Logger;