Refactor to default to structured logging.
- Added `flattenMessage` and `FlattenedLogMessage` to default to structured logging. - Rework the logic formatting messages for the ConsoleLogger. - Add a more comprehensive README.
This commit is contained in:
12
src/util.ts
Normal file
12
src/util.ts
Normal file
@ -0,0 +1,12 @@
|
||||
export function omit(
|
||||
obj: Record<string, unknown>,
|
||||
keys: string[],
|
||||
): Record<string, unknown> {
|
||||
const result: Record<string, unknown> = {};
|
||||
for (const key in obj) {
|
||||
if (!keys.includes(key)) {
|
||||
result[key] = obj[key];
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
Reference in New Issue
Block a user