Skip to content
This repository was archived by the owner on Jul 19, 2025. It is now read-only.

Commit db3200c

Browse files
sxzzLittleSound
authored andcommitted
refactor(compiler-vapor): extract new block
1 parent 9806ad8 commit db3200c

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

packages/compiler-vapor/src/transforms/transformSlotOutlet.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import {
2020
type VaporDirectiveNode,
2121
} from '../ir'
2222
import { camelize, extend, isBuiltInDirective } from '@vue/shared'
23-
import { newDynamic } from './utils'
23+
import { newBlock } from './utils'
2424
import { buildProps } from './transformElement'
2525

2626
export const transformSlotOutlet: NodeTransform = (node, context) => {
@@ -122,15 +122,7 @@ function createFallback(
122122
children: [...node.children],
123123
})
124124

125-
const fallback: BlockIRNode = {
126-
type: IRNodeTypes.BLOCK,
127-
node,
128-
dynamic: newDynamic(),
129-
effect: [],
130-
operation: [],
131-
returns: [],
132-
}
133-
125+
const fallback: BlockIRNode = newBlock(node)
134126
const exitBlock = context.enterBlock(fallback)
135127
context.reference()
136128
return [fallback, exitBlock]

0 commit comments

Comments
 (0)