mirror of https://github.com/sveltejs/svelte
always create outro method for top-level block - fixes #1470
parent
cffbd2709c
commit
f97601ff1d
@ -0,0 +1 @@
|
||||
<div>A wild component appears</div>
|
@ -0,0 +1,15 @@
|
||||
export default {
|
||||
skipIntroByDefault: true,
|
||||
nestedTransitions: true,
|
||||
|
||||
data: {
|
||||
foo: true,
|
||||
},
|
||||
|
||||
html: '<div>A wild component appears</div>',
|
||||
|
||||
test(assert, component, target) {
|
||||
component.set({ foo: false });
|
||||
assert.htmlEqual(target.innerHTML, '');
|
||||
},
|
||||
};
|
@ -0,0 +1,11 @@
|
||||
{#if foo}
|
||||
<Widget/>
|
||||
{/if}
|
||||
|
||||
<script>
|
||||
export default {
|
||||
components: {
|
||||
Widget: './Widget.html'
|
||||
}
|
||||
};
|
||||
</script>
|
Loading…
Reference in new issue