mirror of
https://git.femboyfinancial.jp/james/FemScoreboard.git
synced 2026-02-19 13:33:08 -08:00
Fix imports
This commit is contained in:
22
logging.ts
Normal file
22
logging.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
/**
|
||||
* logging.ts
|
||||
* Standardized logging helper functions
|
||||
*/
|
||||
|
||||
function curDateStr() {
|
||||
return new Date().toJSON().replace('T', ' ').replace('Z', '');
|
||||
}
|
||||
|
||||
function logInfo(...data) {
|
||||
console.log(`[${curDateStr()}] ${data.join(' ')}`);
|
||||
}
|
||||
|
||||
function logWarn(...data) {
|
||||
console.warn(`[${curDateStr()}] ${data.join(' ')}`);
|
||||
}
|
||||
|
||||
function logError(...data) {
|
||||
console.error(`[${curDateStr()}] ${data.join(' ')}`);
|
||||
}
|
||||
|
||||
export { logInfo, logWarn, logError };
|
||||
Reference in New Issue
Block a user