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.
17 lines
274 B
17 lines
274 B
7 years ago
|
<Foo>
|
||
|
{{#await thePromise}}
|
||
|
<p>loading...</p>
|
||
|
{{then theValue}}
|
||
|
<p>the value is {{theValue}}</p>
|
||
|
{{catch theError}}
|
||
|
<p>oh no! {{theError.message}}</p>
|
||
|
{{/await}}
|
||
|
</Foo>
|
||
|
|
||
|
<script>
|
||
|
import Foo from './Foo.html';
|
||
|
|
||
|
export default {
|
||
|
components: { Foo }
|
||
|
};
|
||
|
</script>
|