mirror of
https://github.com/kevin-DL/sapper-template.git
synced 2026-01-22 06:15:18 +00:00
aspirational approach to differential bundling
This commit is contained in:
@@ -23,10 +23,9 @@
|
||||
|
||||
<script>
|
||||
export default {
|
||||
preload({ params, query }) {
|
||||
return this.fetch(`blog.json`).then(r => r.json()).then(posts => {
|
||||
return { posts };
|
||||
});
|
||||
async preload({ params, query }) {
|
||||
const posts = await this.fetch(`blog.json`).then(r => r.json());
|
||||
return { posts };
|
||||
}
|
||||
};
|
||||
</script>
|
||||
Reference in New Issue
Block a user