1

I have a bookmark (Scheme REPL) and it doesn't work on the same pages because of Content Security Policy. But the error is in the console:

Example from GitHub:

VM70:1 Refused to load the script 'https://cdn.jsdelivr.net/npm/jquery' because it violates the following Content Security Policy directive: "script-src github.githubassets.com". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback.

Is there a way to detect that the page has CSP, so I could call an alert() with a message that this bookmark will not work on this page?

jcubic
  • 61,973
  • 54
  • 229
  • 402

0 Answers0