I'm using window.open and on click, it opens a new window, pre-fills the address bar but does not open the url filled in the address bar (for chrome)
window.open("www.stackoverflow.com","_blank")
Is there something that I'm doing wrong.
I'm using window.open and on click, it opens a new window, pre-fills the address bar but does not open the url filled in the address bar (for chrome)
window.open("www.stackoverflow.com","_blank")
Is there something that I'm doing wrong.
You're missing the protocol (in your example http
or https
).
window.open("https://www.stackoverflow.com","_blank")
It's important for the browser to know if you're passing an absolute or relative uri. If it's absolute (like in your case), you have to prepend the protocol.