From 48152bc88ea817ae23e2987dce99d64b426366c1 Mon Sep 17 00:00:00 2001 From: Evan You Date: Sat, 25 Jan 2020 22:31:29 -0500 Subject: [PATCH] fix(runtime-dom): should not access document in non-browser env fix #657 --- packages/runtime-dom/src/nodeOps.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/runtime-dom/src/nodeOps.ts b/packages/runtime-dom/src/nodeOps.ts index 332e6654c45..291eecd05a5 100644 --- a/packages/runtime-dom/src/nodeOps.ts +++ b/packages/runtime-dom/src/nodeOps.ts @@ -1,4 +1,4 @@ -const doc = document +const doc = (typeof document !== 'undefined' ? document : null) as Document const svgNS = 'http://www.w3.org/2000/svg' export const nodeOps = {