lowcode-engine
lowcode-engine copied to clipboard
引擎能力被 CSP 安全策略阻拦
bug 说明
将下面代码插入到 lowcode-demo 项目 index.ejs 文件 head 标签中即可出现
<meta http-equiv="Content-Security-Policy" content="script-src 'unsafe-eval' https: http: 'nonce-abcd';" />


异常具体指向这一行。
对于页面 HTTP 头有 content-security-policy 设置的,会同样出现上述问题。所以此问题常常是本地开发好了,生产环境挂了

期望
Google 对于 document.write 的说明:https://developer.chrome.com/blog/removing-document-write/
期望取消 document.write 的使用,PR 在下方。
具体什么场景要使用这种 CSP 策略啊?