perf(compiler-core): treat v-for with constant exp as a stable fragment (#1394)
This commit is contained in:
@@ -281,7 +281,7 @@ export interface VNodeCall extends Node {
|
||||
dynamicProps: string | undefined
|
||||
directives: DirectiveArguments | undefined
|
||||
isBlock: boolean
|
||||
isForBlock: boolean
|
||||
disableTracking: boolean
|
||||
}
|
||||
|
||||
// JS Node Types ---------------------------------------------------------------
|
||||
@@ -492,7 +492,7 @@ export interface ForCodegenNode extends VNodeCall {
|
||||
props: undefined
|
||||
children: ForRenderListExpression
|
||||
patchFlag: string
|
||||
isForBlock: true
|
||||
disableTracking: boolean
|
||||
}
|
||||
|
||||
export interface ForRenderListExpression extends CallExpression {
|
||||
@@ -543,7 +543,7 @@ export function createVNodeCall(
|
||||
dynamicProps?: VNodeCall['dynamicProps'],
|
||||
directives?: VNodeCall['directives'],
|
||||
isBlock: VNodeCall['isBlock'] = false,
|
||||
isForBlock: VNodeCall['isForBlock'] = false,
|
||||
disableTracking: VNodeCall['disableTracking'] = false,
|
||||
loc = locStub
|
||||
): VNodeCall {
|
||||
if (context) {
|
||||
@@ -567,7 +567,7 @@ export function createVNodeCall(
|
||||
dynamicProps,
|
||||
directives,
|
||||
isBlock,
|
||||
isForBlock,
|
||||
disableTracking,
|
||||
loc
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user