我正在尝试为我的cordova应用程序设置worker-src。当我为浏览器构建cordova时,它显示
plugin.min.js:582 Refused to create a worker from
'blob:http://localhost:8000/a641e3c9-53b6-4a67-bf4f-281a66e78530'
because it violates the following Content Security Policy
directive: "script-src * 'unsafe-inline' 'unsafe-eval'".
Note that 'worker-src' was not explicitly set, so 'script-src'
is used as a fallback
因此,我尝试通过https://content-security-policy.com/
来设置worker-src,但它们没有类似worker-src
的东西。我该如何解决?任何想法将不胜感激。谢谢。
答案 0 :(得分:1)
您应该使用child-src而不是worker-src 例如。是
{{1}}