]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
workflow(template-explorer): handle debugging with nodeTransforms
authorEvan You <yyx990803@gmail.com>
Mon, 6 Dec 2021 03:51:56 +0000 (11:51 +0800)
committerEvan You <yyx990803@gmail.com>
Mon, 6 Dec 2021 03:51:56 +0000 (11:51 +0800)
packages/template-explorer/src/index.ts

index d083d35ca4e950948d2ed889f8fd0da207527b46..1e8efdb95d6f89300651c5722e19a560b95fd9b1 100644 (file)
@@ -40,6 +40,9 @@ window.init = () => {
       localStorage.getItem('state') ||
       `{}`
   )
+  // functions are not persistable, so delete it in case we sometimes need
+  // to debug with custom nodeTransforms
+  delete persistedState.options.nodeTransforms
 
   ssrMode.value = persistedState.ssr
   Object.assign(compilerOptions, persistedState.options)