Message from JavaScript talks

July 2017

— Https://m.youtube.com/watch?feature=youtu.be&v=g8_g5WXmMC0

— 

Guys how to change the url without reload ? for example my website
Https://something.com
I want it to be
https://meow.com
Without reload

— I think it from the hosting/server option

— History API I think. history.pushState or something

— At least that's the way all the SPA routers' change paths

— Have u got an example ?
I searched alot but with no avail

— Just check MDN?

— Https://developer.mozilla.org/en-US/docs/Web/API/History_API#Example_of_pushState()_method

— Thanks

— You're not able to change the domain, just the path

— Ok

— Otherwise you could make phishing very easy.. throw in Facebook login, change the displayed url to Facebook.com

Message permanent page