8 lines
306 B
TypeScript
8 lines
306 B
TypeScript
import { ErrorReporter } from "@core/shared/domain";
|
|
|
|
export class ConsoleErrorReporter implements ErrorReporter {
|
|
report(error: Error, context?: unknown): void {
|
|
const timestamp = new Date().toISOString();
|
|
console.error(`[${timestamp}] Error reported:`, error.message, { error, context });
|
|
}
|
|
} |