From 1c6ecf414493e6e931ad0f5e0e5c9b848ea3d7bf Mon Sep 17 00:00:00 2001 From: Evan You Date: Sat, 31 Aug 2019 16:43:02 -0400 Subject: [PATCH] wip: avoid including full error type strings in prod --- packages/runtime-core/src/errorHandling.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/runtime-core/src/errorHandling.ts b/packages/runtime-core/src/errorHandling.ts index 0a01314575..7cad6a3525 100644 --- a/packages/runtime-core/src/errorHandling.ts +++ b/packages/runtime-core/src/errorHandling.ts @@ -88,7 +88,8 @@ export function handleError( errorCapturedHooks[i]( err, instance && instance.renderProxy, - ErrorTypeStrings[type] + // in production the hook receives only the error code + __DEV__ ? ErrorTypeStrings[type] : type ) ) { return -- 2.47.3