vs2010:尝试使用 Chrome 调试 javascript:这不是断点的有效位置
每次我尝试在 Javascript 中设置调试点,即在设计模式或运行时,都会收到错误:
trying to set a breakpoint in javascript: this is not a valid location for a breakpoint
当我进入 VS2010 的选项屏幕中的“及时调试”时,我会看到“托管”、“本机”和“调试点”。选择脚本后,
我还放置了“debugger;”行在被调用但从未命中中断的 JavaScript 函数的第一行中。
在 Web.Config 中(虽然这可能适用于编译代码:):
<compilation debug="true
我正在一台新机器上重温这个问题......你能帮忙吗?
编辑:我遗漏了一个很大的细节:
Google Chrome 是我的默认浏览器。
(我正在尝试调试仅限 Chrome 的错误。)
我必须求助于 VS2010 以外的其他调试工具吗?我认为它应该有效。太有希望了吧?
Everytime I try to set a debug point in Javascript, eietehr while in Design mode or while runniong, I get the error:
trying to set a breakpoint in javascript: this is not a valid location for a breakpoint
When I go to VS2010's Options screen under Debugging Just In Time, I see that Managed, Native & Script are selected,
I also placed the line "debugger;" in the first line of a javascript function that is called but the break is never hit.
In the Web.Config (although this is probably for compiled code:):
<compilation debug="true
I'm reliving this problem on a new machine...Can u help?
Edit: I left out a huge detail:
Google Chrome is my default browser.
(I am trying to debug a Chrome-only error.)
Must I resort to other debug tools other than VS2010? I am thinking that it should work. Too hopeful, eh?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以单独在 chrome 中调试 javascript。
看这个
如何在 Google Chrome 中启动 JavaScript 调试器?< /a>
http://www.youtube.com/watch?v=c_oiQYirKuY&feature= player_embedded
https://developer.chrome.com/devtools
http://www.chromium.org/devtoolsYou can debug javascript within chrome alone.
See this
How do you launch the JavaScript debugger in Google Chrome?
http://www.youtube.com/watch?v=c_oiQYirKuY&feature=player_embedded
https://developer.chrome.com/devtools
http://www.chromium.org/devtools据我所知,Visual Studio 只调试在 IE 中运行的 js。 chrome 有一个控制台类型的调试器,我不知道如何使用它 - 它可以从页面图标&gt;开发人员&gt;javascript控制台获得。您还可以查看 chrome 扩展,看看是否有人创建了更好的调试器。我知道有一个 Firebug 扩展可用,但我不确定它提供什么功能。
如果一切都失败了:
visual studio only debugs js running in IE, as far as I'm aware. chrome has a console-type debugger which I have no idea how to use- it's available from the page icon>developer>javascript console. you could also look into chrome extensions to see if anyone has created a nicer debugger. i know there's a firebug extension available but i'm not sure what features it offers.
if all else fails: