wip(compiler-ssr): v-show

This commit is contained in:
Evan You
2020-02-04 21:03:16 -05:00
parent e2c5060fb4
commit 1958314976
4 changed files with 122 additions and 5 deletions

View File

@@ -699,10 +699,12 @@ function genConditionalExpression(
}
needNewline && indent()
context.indentLevel++
needNewline || push(` `)
push(`? `)
genNode(consequent, context)
context.indentLevel--
needNewline && newline()
needNewline || push(` `)
push(`: `)
const isNested = alternate.type === NodeTypes.JS_CONDITIONAL_EXPRESSION
if (!isNested) {