![](/img/trans.png)
[英]Chrome Error - Resource interpreted as Script but transferred with MIME type text/plain
[英]Cordova plugin error: Resource interpreted as Script but transferred with MIME type text/plain
我正在將Cordova 4與Cross-walk一起使用,並且在android上,所有插件的javascript文件都會拋出“資源解釋為腳本,但以MIME類型文本/純文本傳輸”的錯誤。
我已經添加了白名單插件,並將以下內容添加到我的index.html文件中:
<meta http-equiv="Content-Type" content="application/javascript; charset=UTF-8">
<meta http-equiv="Content-Security-Policy" content="default-src *; style-src * 'unsafe-inline'; script-src * 'unsafe-inline' 'unsafe-eval'">
這些到config.xml
<allow-navigation href="*"/>
<allow-intent href="*"/>
我相信這些不是“真正的”錯誤,而是特定於Chrome的:請參見此答案
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.