fix(compiler-sfc): treat const reactive() bindings as mutable

This commit is contained in:
Evan You
2021-02-10 11:38:19 -05:00
parent cf67306032
commit 03360cefa1
2 changed files with 7 additions and 4 deletions

View File

@@ -79,7 +79,7 @@ export const transformFor = createStructuralDirectiveTransform(
const isStableFragment =
forNode.source.type === NodeTypes.SIMPLE_EXPRESSION &&
forNode.source.constType > ConstantTypes.CAN_SKIP_PATCH
forNode.source.constType > ConstantTypes.NOT_CONSTANT
const fragmentFlag = isStableFragment
? PatchFlags.STABLE_FRAGMENT
: keyProp