mirror of https://github.com/sveltejs/svelte
parent
7d949a601c
commit
d398b34a41
@ -0,0 +1,6 @@
|
||||
import { Validator } from '../../';
|
||||
import { Node } from '../../../interfaces';
|
||||
|
||||
export default function store(validator: Validator, prop: Node) {
|
||||
// not sure there's anything we need to check here...
|
||||
}
|
@ -0,0 +1,9 @@
|
||||
export default {
|
||||
html: `<h1>Hello world!</h1>`,
|
||||
|
||||
test(assert, component, target) {
|
||||
component.store.set({ name: 'everybody' });
|
||||
|
||||
assert.htmlEqual(target.innerHTML, `<h1>Hello everybody!</h1>`);
|
||||
}
|
||||
};
|
@ -0,0 +1,11 @@
|
||||
<h1>Hello {{$name}}!</h1>
|
||||
<script>
|
||||
import { Store } from '../../../../store.js';
|
||||
export default {
|
||||
store () {
|
||||
return new Store({
|
||||
name: 'world'
|
||||
});
|
||||
}
|
||||
}
|
||||
</script>
|
Loading…
Reference in new issue