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.
svelte/test/runtime/samples/each-block-keyed-unshift/_config.js

21 lines
304 B

export default {
props: {
titles: [{ name: 'b' }, { name: 'c' }]
},
html: `
<p>b</p>
<p>c</p>
`,
test({ assert, component, target }) {
component.titles = [{ name: 'a' }, { name: 'b' }, { name: 'c' }];
assert.htmlEqual(target.innerHTML, `
<p>a</p>
<p>b</p>
<p>c</p>
`);
}
};