Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Replace %sapper.main% with %sapper.scripts% #86

Closed
Rich-Harris opened this issue Jan 14, 2018 · 1 comment
Closed

Replace %sapper.main% with %sapper.scripts% #86

Rich-Harris opened this issue Jan 14, 2018 · 1 comment

Comments

@Rich-Harris
Copy link
Member

In Sapper < 0.4, the client-side app is inserted with this line in template/2xx.html:

<script src='%sapper.main%'></script>

We need to change that so that Sapper has more control over what is inserted, so that (for example) we can add a JSON blob of data generated in preload on the server, to fix #3.

As of version 0.4, including %sapper.main% will cause an error on startup, linking back to this issue. Instead, templates should include `%sapper.scripts%:

-<script src='%sapper.main%'></script>
+%sapper.scripts%
@Rich-Harris
Copy link
Member Author

Closed by #87

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant