aspirational approach to differential bundling

This commit is contained in:
Rich Harris
2018-08-30 20:54:56 -04:00
parent 0e42fd13c5
commit 10d30e4ea4
4 changed files with 29 additions and 4 deletions

View File

@@ -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>