拒绝应用样式,因为其 MIME 类型 ('application/octet-stream')

Refused to apply style because its MIME type ('application/octet-stream')

我在使用版本控制时导入 css 和 javascript 时遇到问题。 看起来当我使用 styles.css 和 script.js 时一切正常,但是当我使用 styles.css?v=1.1script.js?v=1.1 - 我收到以下错误。

Refused to apply style from 'url/goes/here/styles.css?v=1.1' because its MIME type ('application/octet-stream') is not a supported stylesheet MIME type, and strict MIME checking is enabled.

Refused to execute script from 'url/goes/here/script.js?v=2.1' because its MIME type ('application/octet-stream') is not executable, and strict MIME type checking is enabled.

这可能是什么原因?!

它们是这样导入的:

<link rel="stylesheet" type="text/css" href="url/goes/here/styles.css?v=1.1">

<script type="text/javascript" src="url/goes/here/script.js?v=1.1"></script>

我觉得是服务器的问题,去把css文件的"content-type"改成"text/css",把js文件改成"text/javascript",应该可以解决问题