3 ms·
Well client side routing is fundamentally broken unless you do serve a 200 and the index
by antihero 3y ago
Well client side routing is fundamentally broken unless you do serve a 200 and the index
- shkkmo 3y agoYou only have to serve a 200 and the index for valid routes to have frontend routing working. The complaint is serving a 200 for invalid routes, which breaks all kinds of things and violates web standards.
- egeozcan 3y agoIndeed, for a cost-effective approach with a static host, why not generate placeholder HTML files for all valid routes at compile time? Alternatively, using Astro or a similar tool would be a wise choice :)
- antihero 3y agoThis isn’t really feasible, think about how dynamic routes can be? Can you generate a route for every ID of a thing?