RC-4 | Repo initialization

This commit is contained in:
Oliver-Akins 2024-12-10 01:01:12 -07:00
parent 0787446c8d
commit a48071b29a
11 changed files with 2419 additions and 0 deletions

22
module/utils/Logger.mjs Normal file
View file

@ -0,0 +1,22 @@
const augmentedProps = new Set([
`debug`,
`log`,
`error`,
`info`,
`warn`,
`group`,
`time`,
`timeEnd`,
`timeLog`,
`timeStamp`,
]);
/** @type {Console} */
export const Logger = new Proxy(console, {
get(target, prop, _receiver) {
if (augmentedProps.has(prop)) {
return (...args) => target[prop](game.system.id, `|`, ...args);
};
return target[prop];
},
});