Non hashbased URL rewrite without

Hello,

I have an global SPA question because of the urls. I would like to have non-hash-based urls (push state) and configured my web-server to support push state (IIS).

But copying a link to the browser, the push-state configuration always forwards to the start page (of course).
Now my question is, if there is some solution how to have push-State-Routes and additionally the ability to copy full routes?

1 Like

Can you help elaborate that a bit more?

Unfortunately no.

Server-side “support” for push-state simply means loading the same HTML / CSS / JavaScript for all requests. It’s up to your client side to decide the rendering process.
So, when the URL is first pasted into the browser, your app’s ENTRY POINT is always loaded first.

Please note that I said “ENTRY POINT” instead of “HOME PAGE”. The best thing you can do is to make your entry point as lean and quick to make a routing decision as possible. The “home page” (more like a splash screen / loading screen / whatever you call it) will still be inevitable, but the transition from a loading screen (when done properly) into a content screen won’t be as abrupt / unexpected / annoying as transition from a home screen (which is a content screen) to another content screen.


To REALLY avoid the “splash” screen, you will have to implement server-side rendering.

2 Likes

Ok. Thank you for your response. That was exactly my question.

1 Like