问题标签 [firefox-developer-tools]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
2 回答
880 浏览

javascript - 调试时如何使用firefox开发者版控制台?

我今天正在测试Firefox 开发者版,并注意到虽然我最初可以在 javascript 控制台中执行代码,但当我在 javascript 中设置断点并开始单步执行代码时,控制台将变为非活动状态(我可以输入它,但按下“输入”导致换行而不是发出命令),直到我按下“继续”并且不再单步执行代码。

在 chrome 中,我很欣赏在我正在逐步执行的代码上下文中通过控制台执行 javascript 的能力。这在 Firefox 开发者版中可行吗?谢谢!

0 投票
2 回答
364 浏览

javascript - 在 Mozilla 和 Chrome 中安装证书

如何使用 java 脚本在 Mozilla 和 Chrome 中安装服务器生成的浏览器证书。我有这个方法

但它已经过时并且不起作用。

0 投票
1 回答
1292 浏览

javascript - SourceMap 或 X-SourceMap 处理

我无法让 firefox(或任何浏览器)识别X-SourceMap标题。对于我的代码。该//# SourceMappingURL评论适用于我的浏览器端,但由于特定于我的系统的原因,我无法使用它。

我很好奇在什么条件下X-SourceMap标头用于设置源映射,因为我似乎没有成功。我认为这与我的代码的获取方式有关——开发工具不知何故没有“意识到”我正在获取一个 JavaScript 文件,而该文件的源映射也应该被获取。

https://hg.mozilla.org/mozilla-central/rev/5a0161f8a11e似乎显示了这是如何实现的,但是对于不熟悉此代码库的人来说,不清楚如何确定对X-SourceMap标头进行操作。

0 投票
3 回答
3916 浏览

javascript - 检测何时从控制台调用函数的最佳方法

我想知道检测何时通过控制台直接调用方法或函数的最佳方法。据我目前了解,不可能在相同的函数调用中直接检测到它,但是使用函数的.call()and.apply()方法我可以通过this对象传递额外的数据。

给定以下代码结构:

我可以使用调用该函数

在我的实际代码中将直接从控制台调用和我自己的代码区分开来,但这显然不是万无一失的,因为同样的代码也可以从控制台执行以达到预期的效果。

我想要一种能够从两个地方调用该函数的方法,然后将调用的位置分开。如果没有办法做到这一点,那么尝试阻止执行的最佳方法是什么?最好根本不公开任何方法,并将所有内容保存在一个封闭的匿名函数中吗?

0 投票
2 回答
2294 浏览

javascript - Annoying behaviour of Firefox Developer Edition - Crashes a lot while debugging JS

I am using Firefox regular edition since years and have very seamless experience while browsing and debugging apps. Few months back firefox launched its developer edition, so I switched to FF developer edition. But what I experienced is that, it crashes a lot while debugging JS (angularjs and jquery code) and some times the debugger does not hit at all even though that line of codes are being executed. This is really an annoying behaviour of firefox developer edition. Why it is so unstable even though I haven't installed any addons at all. Is Firefox Developer Edition is unstable or it is something related to my system.

What I observed so far if some line of my code in js (Angular, Jquery or plain vanilla) has any error (like calling any undefined scope variable in controller in angularjs or calling any function from services which is undefined in angularjs) it crashes while executing same in chrome it simply skips that line and shows error in console. For debugging I apply breakpoints at multiple lines and then use F8 to jump line.

Is there any solution to solve this issue?

Here is crash report.

0 投票
3 回答
159 浏览

javascript - 如何找到调用某个函数的地方?

我正在写一个网页,我需要做一些小改动。问题是,我需要找到调用某个函数的地方(有很多 JavaScript 文件,所以我无法逐行浏览它们)。你有什么想法,我怎么能找到它?

我知道如何在 Firebug 或类似的浏览器控制台中进行逐步调试,但我仍然不知道如何识别调用函数的位置。

我更喜欢在 Firefox 或 Chrome 中使用控制台。

0 投票
2 回答
3505 浏览

javascript - 实时 JavaScript 编辑和编译 - Firefox 开发者版

Firefox 最近发布了一个新的“Firefox 开发者版”,原生提供了所有开发功能。

我总是使用 chrome 来满足我的开发人员需求,并考虑尝试一下。搜索但找不到像在 Chrome 中那样实时编辑 JavaScript 和重新编译脚本的方法。

当然,有暂存器,但它不会更改现有脚本,恕我直言,与在控制台中执行脚本没有什么不同。

Firefox 仍然落后于 Chrome 开发者工具吗?或者我错过了如何在 Firefox 中实时编辑 javascript?

参考 :

https://developer.mozilla.org/en/docs/Tools

https://developer.mozilla.org/en-US/Firefox/Developer_Edition

0 投票
4 回答
1098 浏览

firefox-developer-tools - 为什么我的断点会从预期的位置逃跑

尝试在 javascript 中的任何位置设置断点时,我遇到了在 Firefox Developer Edition 中移动到文件末尾的行为。

在此处输入图像描述

有时在重新启动 PC 后或第二天它可以工作,但我不确定是否某些代码会导致此问题,或者这是否是 Firefox 开发人员版中的错误。

0 投票
2 回答
666 浏览

firefox - Firefox 开发者工具中的 3D 视图有哪些用例

我最近注意到 Firefox 开发人员工具中的 3D 模式,您可以在 3D 视图中查看您的页面。我们可以通过拖动来旋转和重新定位 3D 视图。谁能给我使用 3D 视图的主要用例?

示例 3D 视图:在此处输入图像描述

0 投票
1 回答
2475 浏览

asp.net-mvc - 获取 `kendo.all.min.js` 的 kendo telerik 源地图时出现 404 错误

如何kendo.all.min.js在开发人员工具中使用 Firefox 36 在 IIS Express 上运行的 ASP.NET MVC 5 项目中使用源映射?

在我的 html 页面中(如浏览器所示):

kendo.all.min.js

脚步:

  1. 使用开发工具打开带有 FF 的页面并启用“显示原始来源”。结果:脚本被分解为调试器选项卡上的源窗格中显示的许多文件,例如:animation.js、attribution.js、kendo.grid.js 等等。
  2. kendo.core.js在窗格中单击。结果:“HTTP 错误 404.0 - 未找到”错误。

谢谢!