mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-04-25 15:10:30 -04:00
22 lines
939 B
JavaScript
22 lines
939 B
JavaScript
/* Magic Mirror
|
|
* Logger
|
|
* This logger is very simple, but needs to be extended.
|
|
* This system can eventually be used to push the log messages to an external target.
|
|
*
|
|
* By Michael Teeuw https://michaelteeuw.nl
|
|
* MIT Licensed.
|
|
*/
|
|
const Log = (function() {
|
|
return {
|
|
info: Function.prototype.bind.call(console.info, console),
|
|
log: Function.prototype.bind.call(console.log, console),
|
|
error: Function.prototype.bind.call(console.error, console),
|
|
warn: Function.prototype.bind.call(console.warn, console),
|
|
group: Function.prototype.bind.call(console.group, console),
|
|
groupCollapsed: Function.prototype.bind.call(console.groupCollapsed, console),
|
|
groupEnd: Function.prototype.bind.call(console.groupEnd, console),
|
|
time: Function.prototype.bind.call(console.time, console),
|
|
timeEnd: Function.prototype.bind.call(console.timeEnd, console),
|
|
timeStamp: Function.prototype.bind.call(console.timeStamp, console)
|
|
};
|
|
})();
|