如何在 VS2017 中禁用新的调试窗口 [英] How to disable the new debug window in VS2017

查看:40
本文介绍了如何在 VS2017 中禁用新的调试窗口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Visual Studio 2017 RC,对单击调试"时弹出的新 Chrome 窗口感到非常沮丧.

I'm using Visual Studio 2017 RC and getting very frustrated with the new Chrome window that pops up when you click Debug.

调试 Chrome 窗口的问题:

Issues with the Debug Chrome Window:

  • 需要很长时间才能启动/附加"网站(我认为它附加了所有我不需要的 javascript 调试,因为无论如何我都使用 Chrome DevTools)
  • 不能与其他 Chrome 窗口停靠(作为选项卡)
  • 不记得表单历史记录.如果我正在测试表单,我无法自动完成表单数据,所以我每次都必须输入全部内容
  • 不记得网址历史记录.如果我在我的网站上测试特定页面,我无法从 Chrome 网址栏下拉菜单中快速选择网址.必须完整输入网址
  • 未启用扩展,因此我无法使用我的标尺或颜色选择器扩展
  • Chrome 窗口在调试停止时关闭,因此我必须打开一个新窗口才能继续浏览本地站点

有谁知道如何禁用这个新的 Debug 样式窗口并回到 VS 2015 中的状态?

Does anyone know how to disable this new Debug style window and go back to how it was in VS 2015?

推荐答案

这不是问题,而是 VS 2017 中的新功能.以前我们只能在调试模式下(VS)使用 IE 调试 JS 和 TypeScript.但是现在他们已经引入了使用 Chrome 的远程调试功能在 VS 中调试 JS 和 TS.如果您在调试模式下运行应用程序(按 F5)并且选择了 Chrome 浏览器,Visual Studio 2017 将尝试在专用端口上使用 Chrome 打开远程调试会话.通过远程调试,

This is not an issue, rather a new feature in VS 2017. Previously we could only debug JS and TypeScript using IE in debug mode (of VS). But now they have introduced debugging JS and TS inside VS using Remote Debugging feature of Chrome. If you are running your application in debug mode (pressing F5) and Chrome is selected browser, Visual studio 2017 will try to open a remote debugging session with Chrome on a dedicated port. With remote debugging,

  1. 浏览器以普通模式启动,即没有扩展程序和历史记录等.远程调试不适用于已经运行的现有 Chrome 实例.

  1. The browser is launched in plain mode, i.e. no extension and no history etc. Remote debuggin doesnt work with an existing instance of Chrome already running.

你总是会看到这个窗口一段时间.此时,VS 正在尝试将远程调试器附加到 VS

You always see this window for a while. At this point, VS is trying to attach the remote debugger to VS

  1. 要回到 VS 2015 的调试体验,请将调试目标从 Chrome 更改为 IIS Express.

这篇文章详细描述了这个功能.https://blogs.msdn.microsoft.com/webdev/2016/11/21/client-side-debugging-of-asp-net-projects-in-google-chrome/

This post describes this feature in detail. https://blogs.msdn.microsoft.com/webdev/2016/11/21/client-side-debugging-of-asp-net-projects-in-google-chrome/

一种快速解决方法是按 F5 并启动调试会话并忘记新打开的 Chrome 窗口.去你的普通的 Chrome 实例,只需在新标签页中打开您的网站.你会仍然能够调试和做所有事情,因为 IIS Express 将仍在该端口上运行您的应用程序.

A kind of quick work around is to press F5 and launch the debug session and forget about the newly opened Chrome window. Go to your normal Chrome instance and just open your site in new tab. You will still be able to debug and do everything because IIS Express will still be running your app at that port.

更新:@Steveadoo 下面给出的答案是正确的前进方向.他的屏幕截图中显示的选项控制如何启动 chrome 进行调试.如果您想坚持使用常规 Chrome 实例,请取消选中它.

Update: The answer given below by @Steveadoo is the right way going forward. The option shown in his screenshot controls how chrome is launched for debugging. Uncheck it if you want to stick to your regular Chrome instance.

希望这会有所帮助.

这篇关于如何在 VS2017 中禁用新的调试窗口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆