mirror of https://github.com/sveltejs/svelte
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
452 B
19 lines
452 B
4 years ago
|
export default {
|
||
|
html: `
|
||
|
<span>bye</span><span>world</span>
|
||
|
<span slot="a">hello world</span>
|
||
|
$$slots: {"a":true,"default":true}
|
||
|
Slot b is not available
|
||
|
|
||
|
<span>bye world</span>
|
||
|
<span slot="a">hello world</span>
|
||
|
$$slots: {"a":true,"b":true,"default":true}
|
||
|
<div><span slot="b">hello world</span></div>
|
||
|
`,
|
||
|
|
||
|
async test({ assert, target, component }) {
|
||
|
assert.equal(component.getA(), '');
|
||
|
assert.equal(component.getB(), 'foo');
|
||
|
}
|
||
|
};
|