【问题标题】:How to debug Greasemonkey/Tampermonkey userscripts with FF 57+ (with WebExtensions)?如何使用 FF 57+(使用 WebExtensions)调试 Greasemonkey/Tampermonkey 用户脚本?
【发布时间】:2021-10-04 21:56:50
【问题描述】:

我在浏览器调试器的 打开文件... 框中找不到我的用户脚本(名称定义在 // @name)。

似乎Annarfych's answerHjulle's answerHow to debug Greasemonkey script with the Firebug extension? 不再起作用了。

因为Michael's findingsGreasemonkey script folder missing

显然 GreaseMonkey 不再将用户脚本存储在 Firefox 的 gm_scripts 中。 [...] 脚本显然存储在 SQLite 数据库文件中。

【问题讨论】:

    标签: debugging greasemonkey tampermonkey userscripts firefox-57+


    【解决方案1】:

    因为到现在都没有答案:

    • 打开 DevTools (F12) > 调试器
    • Tampermonkey 的用户脚本存储在插件文件夹Tampermonkey > userscripts 文件夹中
    • 对于 Greasemonkey,用户脚本存储在文件夹 user-script:// > 用户脚本的命名空间 > 用户脚本名称

    【讨论】:

    • 在我的 FF 92.0.1 的 DebuggerSources 中有一个 Main-ThreadTampermonkey 文件夹有两个文件:rea/common.jscontent.js,并且根本没有 Greasemonkey 文件夹。我安装了其他附加组件的文件夹:Native MathMLuMatrix 等。
    猜你喜欢
    • 2018-04-29
    • 2013-10-23
    • 2016-10-03
    • 2011-03-30
    • 1970-01-01
    • 1970-01-01
    • 2015-06-17
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多