Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export function render(_ctx) {
"default": _withVaporCtx(() => {
const n0 = _createIf(() => (true), () => {
const n3 = t0()
_setInsertionState(n3, null, 0, true)
_setInsertionState(n3, null, 0)
const n2 = _createComponentWithFallback(_component_Bar)
_withVaporDirectives(n2, [[_directive_hello, void 0, void 0, { world: true }]])
return n3
Expand Down Expand Up @@ -159,7 +159,7 @@ export function render(_ctx, $props, $emit, $attrs, $slots) {
const n3 = t1()
const n2 = _child(n3, 1)
_renderEffect(() => _setProp(n3, "id", _ctx.foo))
_setInsertionState(n3, 0, 0, true)
_setInsertionState(n3, 0, 0)
const n1 = _createComponentWithFallback(_component_Comp)
_renderEffect(() => _setText(n2, _toDisplayString(_ctx.bar)))
return [n0, n3]
Expand Down Expand Up @@ -223,7 +223,7 @@ export function render(_ctx, $props, $emit, $attrs, $slots) {
const n5 = _next(n2, 1)
const n4 = _next(n5, 2)
const x2 = _txt(n2)
_setInsertionState(n6, n5, 1, true)
_setInsertionState(n6, n5, 1)
const n3 = _createComponentWithFallback(_component_Child)
const x4 = _txt(n4)
_renderEffect(() => _setText(x4, _toDisplayString(_ctx.useId())))
Expand All @@ -246,7 +246,7 @@ export function render(_ctx, $props, $emit, $attrs, $slots) {
const _component_Child = _resolveComponent("Child")
const n1 = t0()
_renderEffect(() => _setProp(n1, "id", _ctx.useId()))
_setInsertionState(n1, null, 0, true)
_setInsertionState(n1, null, 0)
const n0 = _createComponentWithFallback(_component_Child)
return n1
}"
Expand Down Expand Up @@ -280,7 +280,7 @@ export function render(_ctx) {
const n4 = _child(p0)
_setInsertionState(n6, n5, 1)
const n0 = _createComponentWithFallback(_component_Comp)
_setInsertionState(n6, n7, 3, true)
_setInsertionState(n6, n7, 3)
const n1 = _createIf(() => (true), () => {
const n3 = t0()
return n3
Expand All @@ -298,9 +298,9 @@ export function render(_ctx) {
const _component_Comp = _resolveComponent("Comp")
const n3 = t0()
const n1 = _child(n3)
_setInsertionState(n1, null, 0, true)
_setInsertionState(n1, null, 0)
const n0 = _createSlot("default", null)
_setInsertionState(n3, null, 1, true)
_setInsertionState(n3, null, 1)
const n2 = _createComponentWithFallback(_component_Comp)
return n3
}"
Expand Down
2 changes: 1 addition & 1 deletion packages/compiler-vapor/__tests__/compile.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ describe('compile', () => {
})
expect(code).contains(
`_renderEffect(() => _setProp(n1, "id", _ctx.useId()))
_setInsertionState(n1, null, 0, true)
_setInsertionState(n1, null, 0)
const n0 = _createComponentWithFallback(_component_Child)`,
)
expect(code).matchSnapshot()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export function render(_ctx) {
return n5
}, () => {
const n14 = t2()
_setInsertionState(n14, 0, 0, true)
_setInsertionState(n14, 0, 0)
const n9 = _createIf(() => (_ctx.c), () => {
const n11 = t1()
return n11
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export function render(_ctx) {
const n3 = _next(_child(n2), 2)
_setInsertionState(n2, 0, 0)
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n2, n3, 2, true)
_setInsertionState(n2, n3, 2)
const n1 = _createComponentWithFallback(_component_Comp2)
return n2
}"
Expand All @@ -31,7 +31,7 @@ export function render(_ctx) {
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n3, 0, 1)
const n1 = _createComponentWithFallback(_component_Comp2)
_setInsertionState(n3, n4, 3, true)
_setInsertionState(n3, n4, 3)
const n2 = _createComponentWithFallback(_component_Comp3)
return n3
}"
Expand All @@ -48,7 +48,7 @@ export function render(_ctx) {
const n4 = _next(_child(n5), 1)
_setInsertionState(n5, n4, 1)
const n0 = _createComponentWithFallback(_component_Comp)
_setInsertionState(n5, null, 3, true)
_setInsertionState(n5, null, 3)
const n1 = _createIf(() => (true), () => {
const n3 = t0()
return n3
Expand All @@ -69,7 +69,7 @@ export function render(_ctx) {
const n6 = _nthChild(n5, 3, 3)
_setInsertionState(n5, n4, 1)
const n0 = _createComponentWithFallback(_component_Comp)
_setInsertionState(n5, n6, 3, true)
_setInsertionState(n5, n6, 3)
const n1 = _createIf(() => (true), () => {
const n3 = t0()
return n3
Expand All @@ -88,7 +88,7 @@ export function render(_ctx) {
const n2 = t0()
_setInsertionState(n2, null, 1)
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n2, null, 2, true)
_setInsertionState(n2, null, 2)
const n1 = _createComponentWithFallback(_component_Comp2)
return n2
}"
Expand All @@ -101,7 +101,7 @@ const t0 = _template("<div>", true)
export function render(_ctx) {
const _component_Comp = _resolveComponent("Comp")
const n1 = t0()
_setInsertionState(n1, null, 0, true)
_setInsertionState(n1, null, 0)
const n0 = _createComponentWithFallback(_component_Comp)
return n1
}"
Expand All @@ -114,7 +114,7 @@ const t0 = _template("<div><span>A", true)
export function render(_ctx) {
const _component_Comp = _resolveComponent("Comp")
const n1 = t0()
_setInsertionState(n1, null, 1, true)
_setInsertionState(n1, null, 1)
const n0 = _createComponentWithFallback(_component_Comp)
return n1
}"
Expand All @@ -131,7 +131,7 @@ export function render(_ctx) {
const n2 = _next(_child(n3), 1)
_setInsertionState(n3, n2, 1)
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n3, n2, 2, true)
_setInsertionState(n3, n2, 2)
const n1 = _createComponentWithFallback(_component_Comp2)
return n3
}"
Expand All @@ -145,7 +145,7 @@ export function render(_ctx) {
const _component_Comp = _resolveComponent("Comp")
const n2 = t0()
const n1 = _next(_child(n2), 1)
_setInsertionState(n2, n1, 1, true)
_setInsertionState(n2, n1, 1)
const n0 = _createComponentWithFallback(_component_Comp)
return n2
}"
Expand All @@ -158,7 +158,7 @@ const t1 = _template("<div><span>A</span>", true)

export function render(_ctx) {
const n2 = t1()
_setInsertionState(n2, null, 1, true)
_setInsertionState(n2, null, 1)
const n0 = _createKeyedFragment(() => (_ctx.id), () => {
const n1 = t0()
return n1
Expand All @@ -175,7 +175,7 @@ const t1 = _template("<div><span>A</span><!><span>B", true)
export function render(_ctx) {
const n3 = t1()
const n2 = _next(_child(n3), 1)
_setInsertionState(n3, n2, 1, true)
_setInsertionState(n3, n2, 1)
const n0 = _createKeyedFragment(() => (_ctx.id), () => {
const n1 = t0()
return n1
Expand All @@ -191,7 +191,7 @@ const t1 = _template("<div><span>A", true)

export function render(_ctx) {
const n2 = t1()
_setInsertionState(n2, 0, 0, true)
_setInsertionState(n2, 0, 0)
const n0 = _createKeyedFragment(() => (_ctx.id), () => {
const n1 = t0()
return n1
Expand All @@ -210,7 +210,7 @@ export function render(_ctx) {
const n2 = t0()
_setInsertionState(n2, 0, 0)
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n2, null, 2, true)
_setInsertionState(n2, null, 2)
const n1 = _createComponentWithFallback(_component_Comp2)
return n2
}"
Expand All @@ -230,7 +230,7 @@ export function render(_ctx) {
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n3, n4, 2)
const n1 = _createComponentWithFallback(_component_Comp2)
_setInsertionState(n3, null, 4, true)
_setInsertionState(n3, null, 4)
const n2 = _createComponentWithFallback(_component_Comp3)
return n3
}"
Expand All @@ -246,7 +246,7 @@ export function render(_ctx) {
const n2 = t0()
_setInsertionState(n2, 0, 0)
const n0 = _createComponentWithFallback(_component_Comp1)
_setInsertionState(n2, 0, 1, true)
_setInsertionState(n2, 0, 1)
const n1 = _createComponentWithFallback(_component_Comp2)
return n2
}"
Expand All @@ -259,7 +259,7 @@ const t0 = _template("<div><span>A", true)
export function render(_ctx) {
const _component_Comp = _resolveComponent("Comp")
const n1 = t0()
_setInsertionState(n1, 0, 0, true)
_setInsertionState(n1, 0, 0)
const n0 = _createComponentWithFallback(_component_Comp)
return n1
}"
Expand All @@ -271,7 +271,7 @@ const t0 = _template("<div><span>A</span>", true)

export function render(_ctx) {
const n1 = t0()
_setInsertionState(n1, null, 1, true)
_setInsertionState(n1, null, 1)
const n0 = _createSlot("default", null)
return n1
}"
Expand All @@ -283,7 +283,7 @@ const t0 = _template("<div><span>A", true)

export function render(_ctx) {
const n1 = t0()
_setInsertionState(n1, 0, 0, true)
_setInsertionState(n1, 0, 0)
const n0 = _createSlot("default", null)
return n1
}"
Expand All @@ -296,7 +296,7 @@ const t1 = _template("<div><span>A</span>", true)

export function render(_ctx) {
const n3 = t1()
_setInsertionState(n3, null, 1, true)
_setInsertionState(n3, null, 1)
const n0 = _createFor(() => (_ctx.list), (_for_item0) => {
const n2 = t0()
return n2
Expand All @@ -312,7 +312,7 @@ const t1 = _template("<div><span>A", true)

export function render(_ctx) {
const n3 = t1()
_setInsertionState(n3, 0, 0, true)
_setInsertionState(n3, 0, 0)
const n0 = _createFor(() => (_ctx.list), (_for_item0) => {
const n2 = t0()
return n2
Expand All @@ -328,7 +328,7 @@ const t1 = _template("<div><span>A</span>", true)

export function render(_ctx) {
const n3 = t1()
_setInsertionState(n3, null, 1, true)
_setInsertionState(n3, null, 1)
const n0 = _createIf(() => (_ctx.show), () => {
const n2 = t0()
return n2
Expand All @@ -345,7 +345,7 @@ const t1 = _template("<div><span>A</span><!><p>B", true)
export function render(_ctx) {
const n4 = t1()
const n3 = _next(_child(n4), 1)
_setInsertionState(n4, n3, 1, true)
_setInsertionState(n4, n3, 1)
const n0 = _createIf(() => (_ctx.show), () => {
const n2 = t0()
return n2
Expand All @@ -361,7 +361,7 @@ const t1 = _template("<div><span>A", true)

export function render(_ctx) {
const n3 = t1()
_setInsertionState(n3, 0, 0, true)
_setInsertionState(n3, 0, 0)
const n0 = _createIf(() => (_ctx.show), () => {
const n2 = t0()
return n2
Expand Down Expand Up @@ -390,7 +390,7 @@ export function render(_ctx) {
const n5 = t1()
return n5
}, 5, null, 0)
_setInsertionState(n7, null, 2, true)
_setInsertionState(n7, null, 2)
const n6 = _createComponentWithFallback(_component_Comp2)
return n7
}"
Expand All @@ -407,7 +407,7 @@ export function render(_ctx) {
const n6 = t2()
_setInsertionState(n6, 0, 0)
const n0 = _createComponentWithFallback(_component_Comp)
_setInsertionState(n6, 0, 1, true)
_setInsertionState(n6, 0, 1)
const n1 = _createIf(() => (_ctx.show), () => {
const n3 = t0()
return n3
Expand All @@ -428,7 +428,7 @@ const t2 = _template("<div><span>A</span><!><p>B", true)
export function render(_ctx) {
const n6 = t2()
const n5 = _next(_child(n6), 1)
_setInsertionState(n6, n5, 1, true)
_setInsertionState(n6, n5, 1)
const n0 = _createIf(() => (_ctx.show), () => {
const n2 = t0()
return n2
Expand All @@ -450,7 +450,7 @@ const t3 = _template("<div><span>A</span><!><p>B", true)
export function render(_ctx) {
const n8 = t3()
const n7 = _next(_child(n8), 1)
_setInsertionState(n8, n7, 1, true)
_setInsertionState(n8, n7, 1)
const n0 = _createIf(() => (_ctx.a), () => {
const n2 = t0()
return n2
Expand All @@ -473,7 +473,7 @@ const t2 = _template("<div><span>A</span>", true)

export function render(_ctx) {
const n5 = t2()
_setInsertionState(n5, null, 1, true)
_setInsertionState(n5, null, 1)
const n0 = _createIf(() => (_ctx.show), () => {
const n2 = t0()
return n2
Expand Down Expand Up @@ -502,7 +502,7 @@ export function render(_ctx) {
const n4 = t1()
return n4
}, 5, null, 0)
_setInsertionState(n6, null, 2, true)
_setInsertionState(n6, null, 2)
const n5 = _createComponentWithFallback(_component_Comp)
return n6
}"
Expand All @@ -516,7 +516,7 @@ const t2 = _template("<div><span>A", true)

export function render(_ctx) {
const n5 = t2()
_setInsertionState(n5, 0, 0, true)
_setInsertionState(n5, 0, 0)
const n0 = _createIf(() => (_ctx.show), () => {
const n2 = t0()
return n2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const t1 = _template("<div><div></div><!><div>", true)
export function render(_ctx) {
const n4 = t1()
const n3 = _next(_child(n4), 1)
_setInsertionState(n4, n3, 1, true)
_setInsertionState(n4, n3, 1)
const n0 = _createIf(() => (1), () => {
const n2 = t0()
return n2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ const t0 = _template("<div>", true)
export function render(_ctx) {
const _component_Foo = _resolveComponent("Foo")
const n2 = t0()
_setInsertionState(n2, null, 0, true)
_setInsertionState(n2, null, 0)
const n0 = _createKeyedFragment(() => (_ctx.id), () => {
const n1 = _createComponentWithFallback(_component_Foo)
return n1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ const t1 = _template("<div>")
export function render(_ctx) {
const n0 = _createFor(() => (_ctx.list), (_for_item0) => {
const n5 = t1()
_setInsertionState(n5, null, 0, true)
_setInsertionState(n5, null, 0)
const n2 = _createFor(() => (_for_item0.value), (_for_item1) => {
const n4 = t0()
const x4 = _txt(n4)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ export function render(_ctx) {
const n2 = t0()
return n2
}, null, 1)
_setInsertionState(n8, null, 1, true)
_setInsertionState(n8, null, 1)
const n3 = _createIf(() => (_ctx.bar), () => {
const n5 = t1()
return n5
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ const t0 = _template("<div>", true)
export function render(_ctx) {
const _component_Comp = _resolveComponent("Comp")
const n1 = t0()
_setInsertionState(n1, null, 0, true)
_setInsertionState(n1, null, 0)
const n0 = _createComponentWithFallback(_component_Comp, { id: () => (_ctx.foo) }, null, null, true)
return n1
}"
Expand All @@ -66,7 +66,7 @@ const t0 = _template("<div>", true)
export function render(_ctx) {
const n1 = t0()
_setInsertionState(n1, null, 0, true)
_setInsertionState(n1, null, 0)
const n0 = _createSlot("default", null, null, null, true)
return n1
}"
Expand Down
Loading
Loading