From 4ab7838f10d8f5137ef8fbcddc2157ce2ec27801 Mon Sep 17 00:00:00 2001 From: Alain Date: Sun, 19 May 2024 10:19:38 +0800 Subject: [PATCH] output error to console --- source/element.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/source/element.ts b/source/element.ts index 715a3d5..1e78f95 100644 --- a/source/element.ts +++ b/source/element.ts @@ -84,6 +84,7 @@ export function component

(comp: AirxComponent

): AirxComponent

export function createErrorRender(error: unknown): AirxComponentRender { const formattingError = (): string => { + console.error(error) if (error == null) return 'Unknown rendering error' if (error instanceof Error) return error.message return JSON.stringify(error)