mirror of https://github.com/vuejs/vue.git
refactor(codegen): only generate pre data for possible components
This commit is contained in:
parent
0b16927c9d
commit
002acbe678
|
@ -75,7 +75,7 @@ export function genElement (el: ASTElement, state: CodegenState): string {
|
|||
code = genComponent(el.component, el, state)
|
||||
} else {
|
||||
let data
|
||||
if (!el.plain || el.pre) {
|
||||
if (!el.plain || (el.pre && state.maybeComponent(el))) {
|
||||
data = genData(el, state)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue