我使用的是 Ubuntu 版 Firefox,版本 39.0。我正在尝试调试一个附加组件,并希望在 chrome 权限下运行一些 JavaScript。根据 this page 我应该能够在浏览器控制台中执行此操作。
如果我在 Firefox 菜单中单击“工具”->“Web 开发人员”->“浏览器控制台”,我会看到浏览器控制台:
唯一的问题是,我无法评价任何东西。我的问题是:提示在哪里?显然这个窗口应该有一个提示。我尝试过的事情:
有什么建议吗?
您必须启用开发人员首选项:
“设置扩展开发环境”MDN 页面来自
感谢您的研究,看起来这是
devtools.chrome.enabled
的偏好。
您好,当控制台日志窗口中未显示控制台时,要显示 Firefox 浏览器控制台日志,请按照以下步骤操作
https://firefox-source-docs.mozilla.org/devtools-user/browser_console/index.html
NB: The Browser Console command line (to execute JavaScript expressions) is disabled by default. To enable it set the devtools.chrome.enabled preference to true in about:config, or set the “Enable browser chrome and add-on debugging toolboxes” (Firefox 40 and later) option in the developer tool settings.