-
Hey there, I'm looking for help to resolve some code-splitting issues in a unique deployment setup. Background and setup
So far, this is all fairly straightforward when I have complete control over the deployment. Enter Shopify developmentBut this is where it gets tricky. The Vue application is deployed as a Shopify theme extension block for a Shopify app. The main thing that’s relevant here is that Shopify handles the deployment and sets some annoying constraints.
Now when loading the page... things get weird:
Worse, for CSS chunks
I get a mess of console errors for each 404, and a lot of red in the network tab. How to configure for this case?Is this a vite or vite plugin vue concern, or something I should solve for with rollup options? I’m not sure how to move forward. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 6 replies
-
Updated above with a note that...
|
Beta Was this translation helpful? Give feedback.
-
This should not happen. Are you using the latest version? If so, would you create a minimal reproduction?
Assuming you are outputting the bundle as ESM, adding a query param won't work well with ESM. Is it possible to disable that behavior? If it is not possbile, I guess you need to workaround it by serving a proxy module that contains |
Beta Was this translation helpful? Give feedback.
Aha! So I was not using
renderBuildUrl
. But then as I was reading the docs on that more carefully I realized that's exactly what I needed. It took some trial and error with the code outlined here, but looks like I got it working for both JS and CSS chunks.then in my proxy module (to get the CDN URL at runtime)