HumanBrainProject/hbp-validation-framework

Unable to open model page via window.open()

appukuttan-shailesh opened this issue · 1 comments

I am trying to open a model catalog entry in a new tab via its URL on the click of a button when using window.open() in JS. For some reason the new window opens and closes immediately.

To reproduce this problem, try this:
https://www.w3schools.com/jsref/tryit.asp?filename=tryjsref_win_open
It works fine with their example URL.

But the moment I change it to: https://model-catalog.brainsimulation.eu/#model_id.00f2e856-27a8-4b8d-9ec3-4e2581c546e4 the page opens and closes. Happens both on Chrome and Firefox.... and seems to be arising from our app, as other URLs work fine.

Workaround for now is to use anchor tags: <a href={url} target="_blank">...</a>