首页 > 解决方案 > 使用 web-ext 使用 node_module 脚本签署 webextension

问题描述

我正在使用web-ext来签署插件,但我总是收到相同的错误消息:

A content script defined in the manifest could not be found.
Error: Content script defined in the manifest could not be found at "node_modules/jquery/dist/jquery.min.js".

我已经尝试更改manifest.json filewith中的路径./,例如:

"content_scripts": [
    {
      "matches": ["*://*/*"],
      "js": [
        "./node_modules/jquery/dist/jquery.min.js"
      ]
    }
  ]

./但是该消息不断出现,并且由于该消息一直在抱怨,因此它忽略了could not be found at "node_modules/...

不确定是否有办法清除 web-ext 缓存。或者我做错了什么来包含这样的脚本。似乎问题出在 node_modules 脚本上。

提前致谢。

标签: firefox-addon-webextensions

解决方案


推荐阅读