How to set X-Frame-Options in Nuxt.js/Vue.js app

6k Views Asked by At

I want to load a web page inside a iframe tag element.

For example: <iframe src="https://www.google.com/" title="Google"></iframe>

Which gives me this error: Refused to display 'https://www.google.com/' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

How can I solve this problem in Nuxt.js app (or Vue.js - it should be very similar config)? I tried with nuxt-helmet, but according to dosc I can use either DENY or SAMEORIGIN because ALLOW-FROM has limited browser support.

0

There are 0 best solutions below