Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change vite.ssrLoadModule to a plain import() when prerendering #44

Merged
merged 2 commits into from
Apr 5, 2022

Conversation

bensmithett
Copy link
Owner

Fixes #42

One change in 10.0.0 was to switch from a 2-step prerender (build the server bundle, then import & use it) to one (import the Renderer directly into the prerenderer with vite.ssrLoadModule)

However as raised in #42, that meant some assets were being referenced by their original name rather than the cacheable hashed name.

This change switches back to the 2-step prerender, while keeping 10.0.0's switch to ES Modules at the project level.

@bensmithett bensmithett merged commit fbc3c54 into main Apr 5, 2022
@bensmithett bensmithett deleted the fix-asset-hashing branch April 5, 2022 23:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Static build contains invalid URLs referencing the /src/ directory
1 participant