Content Security Policy console errors
See original GitHub issueHi,
I’m facing an issue using nouislider with CSP enabled on my server:
Refused to apply inline style because it violates the following Content Security Policy directive: "style-src 'self'".
addMarking @ nouislider.js:1229
pips @ nouislider.js:1247
closure @ nouislider.js:2114
initialize @ nouislider.js:2135
Basically this happens because the html markup is created in a huge string with inline styles and as soon as you do element.innerHTML = out;
function addMarking ( spread, filterFunc, formatter ) {
...
element.innerHTML = out;
return element;
}
Then the CSP complains about inline style. (UPDATED) this only happens if I enable pips, the normal slide behavior is CSP compliant.
Are you guys aware of this?
ps. Thanks for the great plugin!
Issue Analytics
- State:
- Created 6 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
CSP errors and warnings (Content Security Policy) - HTTP
When you see any of the following messages logged in the browser devtools console, it indicates that a problem related to CSP has...
Read more >Chrome console error: The Content Security Policy was ...
A Content Security Policy or CSP is a header your server can set which tells the browser to enforce a whitelist of what...
Read more >How to fix 'because it violates the following content security ...
'because it violates the following content security policy directive' is a browser error message that occurs when Content Security Policy is blocking a ......
Read more >Fix a content security policy (CSP) error - Affilimate
How to check for content security policy errors. Visit your website, open Chrome Dev Tools, click the Console tab, and check for any...
Read more >Why don't all browser console CSP errors need to be fixed?
Browser console errors: why don't all CSP errors in browser console need to be fixed? Content Security Policy backward compatibility mode.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This only happens here. Shouldn’t be too hard to fix.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.