mirror of https://github.com/vladmandic/human
8 lines
401 B
JavaScript
8 lines
401 B
JavaScript
![]() |
// helper function: wrapper around console output
|
||
|
export function log(...msg) {
|
||
|
const dt = new Date();
|
||
|
const ts = `${dt.getHours().toString().padStart(2, '0')}:${dt.getMinutes().toString().padStart(2, '0')}:${dt.getSeconds().toString().padStart(2, '0')}.${dt.getMilliseconds().toString().padStart(3, '0')}`;
|
||
|
// eslint-disable-next-line no-console
|
||
|
if (msg) console.log(ts, 'Human:', ...msg);
|
||
|
}
|