Comments (9)
where are you deploying qwik to?
from qwik.
looks like google cloud run if you deploy all built files in /build into the same bucket location behind a cdn then this will also fix the problem. in the ssr.entry you can set base to that bucket url
so
base: "https://my-cdn.com/my-path-to-bucket/build/"
from qwik.
not quite sure I'm understanding you :) Everything works as expected, files do exist and are pulled correctly. Our problem (and probably everyone's problem) is that if you make a request for a non-existing JS file (maybe due to caching) that it delivers the 300kb custom JS file instead of a few bytes:
- www.myapp.com/build/q-some-old-non-existent-file.js - 300kb to tell the browser it doesn't exist
The ethos of qwik is that everything is fast and optimised out of the box and developers don't accidentally fall into performance pitfalls, so delivering your custom 300kb 404 page and causing 30mb of wasteful requests is something that developers have to understand and manually fix.
from qwik.
ok the solution was setting cloudflare (that is in front of cloud-run) anything with /build to be cache forever
from qwik.
@PatrickJS although it wouldn't hurt to have the static file serving for the assets base serve simple 404s
from qwik.
yup I agree
from qwik.
I have a draft PR here if anyone wants to take over the PR.
Basically remake it and check that everything works. Possible add a test
#6307
from qwik.
Related Issues (20)
- [✅] fixes for all "Error: Missing Qwik City Env Data" HOT 2
- [🐞] Non-deterministic builds
- [📖] onLoad$ img cookbook
- [🐞] SSG ignoring the index page when trailingSlash is false HOT 3
- [🐞] Disable Link prefetch true by default HOT 2
- [📖] Sidebar Issue HOT 2
- [✨] How to distinguish between link preload and page visit HOT 1
- [🐞] Qwik dev server fails when using mkcert/https because of http2 headers HOT 1
- [📖] Copy the current Qwik docs homepage
- [✨] Throw server$ errors with a specific status code HOT 4
- [🐞] Attribute re-render on spread in polymorphism does not work correctly HOT 1
- [🐞] Route is broken with deep nesting HOT 4
- [✨] Create a unique file name for each version of service-worker.js HOT 16
- [🐞] Error Boundary Issue
- [🐞] Qwik server$ throws 500 error [Firebase deployment] HOT 6
- [🐞] Qwik Auth is not getting published HOT 4
- Link is broken [📖] HOT 6
- [📖] check all links in docs to make sure they work
- [📖] explain uncontrolled vs controlled components HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qwik.