Files
sapper/test/apps/export/src/routes/blog/[slug].html
2019-01-30 10:21:55 -05:00

13 lines
247 B
HTML

<script context="module">
export function preload({ params }) {
return this.fetch(`blog/${params.slug}.json`).then(r => r.json()).then(post => {
return { post };
});
}
</script>
<script>
export let post;
</script>
<h1>{post.title}</h1>