chore: fix codegen error due to scopeId deprecation change

This commit is contained in:
Evan You 2021-07-16 12:24:30 -04:00
parent a27d5cb188
commit 317654b34f
3 changed files with 8 additions and 12 deletions

View File

@ -14,7 +14,7 @@ export function render(_ctx, _cache) {
_createTextVNode(_toDisplayString(_ctx.foo), 1 /* TEXT */),
_hoisted_2
]))
})"
}"
`;
exports[`scopeId compiler support should wrap default slot 1`] = `
@ -29,7 +29,7 @@ export function render(_ctx, _cache) {
]),
_: 1 /* STABLE */
}))
})"
}"
`;
exports[`scopeId compiler support should wrap dynamic slots 1`] = `
@ -56,7 +56,7 @@ export function render(_ctx, _cache) {
}
})
]), 1024 /* DYNAMIC_SLOTS */))
})"
}"
`;
exports[`scopeId compiler support should wrap named slots 1`] = `
@ -74,5 +74,5 @@ export function render(_ctx, _cache) {
]),
_: 1 /* STABLE */
}))
})"
}"
`;

View File

@ -304,10 +304,6 @@ export function generate(
deindent()
push(`}`)
if (genScopeId && !isSetupInlined) {
push(`)`)
}
return {
ast,
code: context.code,

View File

@ -15,7 +15,7 @@ describe('ssr: scopeId', () => {
export function ssrRender(_ctx, _push, _parent, _attrs) {
_push(\`<div\${_ssrRenderAttrs(_attrs)} data-v-xxxxxxx><span data-v-xxxxxxx>hello</span></div>\`)
})"
}"
`)
})
@ -45,7 +45,7 @@ describe('ssr: scopeId', () => {
}),
_: 1 /* STABLE */
}, _parent))
})"
}"
`)
})
@ -74,7 +74,7 @@ describe('ssr: scopeId', () => {
}),
_: 1 /* STABLE */
}, _parent))
})"
}"
`)
})
@ -122,7 +122,7 @@ describe('ssr: scopeId', () => {
}),
_: 1 /* STABLE */
}, _parent))
})"
}"
`)
})
})