Explorar o código

wip: fix defineOptions specifier removal

Evan You %!s(int64=5) %!d(string=hai) anos
pai
achega
dfac6eee99
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      packages/compiler-sfc/src/compileScript.ts

+ 1 - 1
packages/compiler-sfc/src/compileScript.ts

@@ -545,7 +545,7 @@ export function compileScript(
         removed++
         s.remove(
           prev ? prev.end! + startOffset : node.start! + startOffset,
-          next ? next.start! + startOffset : node.end! + startOffset
+          next && !prev ? next.start! + startOffset : node.end! + startOffset
         )
       }