Is there a way to automatically collapse the Scrip

2020-05-18 04:15发布

While in debug mode, the solution explorer has a Script Documents section. It is expanded by default. As the debugger runs, new ScriptDocumentxxx poll.txt files are added to this section. As I am navigating the explorer files, the adding of these new line items causes the entire contents of the explorer to shift downward. This is quite annoying if I am trying to find a file or trying to click something. I can collapse the section manually, but I'd rather not have to do this all of the time.

enter image description here

6条回答
【Aperson】
2楼-- · 2020-05-18 04:48

Yes there is. One way is to create a visual studio add-in or extension which monitors the solution explorer tree and collapses the "script documents" -item if it is expanded.

If you need code samples and/or a fully functional add-in just let me know. You have Visual Studio 2013, ay? Is it the express edition or what?

查看更多
戒情不戒烟
3楼-- · 2020-05-18 04:49

Yes, there is.

Disable Script Debugging

IIS Express > Script Debugging > Disabled

查看更多
混吃等死
4楼-- · 2020-05-18 04:52
Fickle 薄情
5楼-- · 2020-05-18 04:53

Right click then 'Scope to This' to hide everything but the project in the solution you want to view.

Click on the Home/House icon to reverse it.

查看更多
SAY GOODBYE
6楼-- · 2020-05-18 05:09

I got annoyed enough with this that I turned off JavaScript debugging. If you are willing to go that far, the scripts are gone.

The path for turn of JS debugging is:

Tools -> Options -> Debugging -> General -> Enable JavaScript debugging for ASP.NET (Chrome, Edge and IE) (Visual Studio 2017 and 2019)

Note: This method does not prevent you from stepping though JS in the Chrome inspection tools so you do not lose that ability. You lose both the scripts (of course) and that new Chrome window that pops up when you launch the debugger.

查看更多
够拽才男人
7楼-- · 2020-05-18 05:15

Right click the projects you are interested in working on and click on 'Scope to this'. This will hide everything (Including the scripts folder) except those projects you selected.

Visual Studio 'scope to this' example

查看更多
登录 后发表回答