mirror of
https://github.com/hanzoai/babel.git
synced 2026-09-24 16:56:45 +00:00
11 lines
334 B
JavaScript
11 lines
334 B
JavaScript
// @ts-check
|
|
/**
|
|
* Logs a message to the console with a timestamp.
|
|
* @param {string} msg - The message to log.
|
|
* @param {...any} args - Additional arguments to log.
|
|
*/
|
|
exports.log = function (msg, ...args) {
|
|
const time = new Date().toLocaleTimeString("en-US", { hour12: false });
|
|
console.log(`[${time}] ${msg}`, ...args);
|
|
};
|