我正在尝试在我的反应应用程序生产服务器上设置头盔安全性。但每当我尝试点击 URL 时。我收到一条错误消息Refused to execute script from 'http://localhost:3000/static/js/app.378bd8b8eee930fb268c.js' because its MIME type ('application/gzip') is not executable, and strict MIME type checking is enabled.
对于我正在使用的压缩构建compression-webpack-plugin
。
当我删除helmet
. 头盔插件设置:
{"xssFilter": {"setOnOldIE": true}}