Open lol768 opened 4 years ago
Can you explain which part will cause the csp violation, cause I cant locate the inline script. Is it because of the style
attribute?
Please don't do this, for those of us using this library on the web it will break on every sufficiently secured site which doesn't allow script-src 'unsafe-inline'.
Should read:
Please don't do this, for those of us using this library on the web it will break on every sufficiently secured site which doesn't allow style-src 'unsafe-inline'.
Apologies
crisp-edges
is also an attribute in SVG. I've opened a PR to address both: #22.
https://github.com/papnkukn/qrcode-svg/blob/47d56ec28fcd0a3aabbb5f11a34167a02a80c54e/lib/qrcode.js#L312-L317
Please don't do this, for those of us using this library on the web it will break on every sufficiently secured site which doesn't allow
script-src 'unsafe-inline'
.For setting the fill colour, there's a perfectly good
fill
attribute you can use instead. For e.g. the crisp edges rendering, please just put the CSS in the README and let us apply it ourselves