Refused to execute script from because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled

后端 未结 7 1165
误落风尘
误落风尘 2020-12-17 16:25

I am trying to setup react routing which works when I click on something on my site the route works, however if I open a new tab and copy that url. I get

Ref         


        
7条回答
  •  我在风中等你
    2020-12-17 16:47

    Another thing that can cause this is if the contentBase property is not set correctly. This came up for us in that we were requesting a JS file but getting a 404 and the 404 "page" served by webpack-dev-server comes back as text/html.

提交回复
热议问题