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/class-in-each/_config.js

22 lines
351 B

export default {
props: {
things: ['one', 'two', 'three'],
selected: 'two'
},
html: `
<div></div>
<div class="selected"></div>
<div></div>
`,
test({ assert, component, target }) {
component.selected = 'three';
assert.htmlEqual(target.innerHTML, `
<div></div>
<div class=""></div>
<div class="selected"></div>
`);
}
};