Check if a website can be embedded in IFRAME via Javascript -


i have iframe:

<iframe id='url-iframe' src='example.com' width="600px" height="400px"></iframe> 

i want check if example.com can embedded in iframe open in new tab if it's not. i'm using angular 2 typescript. solution written in vanillajs or typescript nice.


Comments