[New Features of VS2017] Debug javascript script in VS and vs2017javascript
1 Overview
VS2017 can debug JS. This article briefly describes how to enable and disable the VS debugging function in VS2017.
2. Details
When the VS2017JS debugging function is enabled, the following interface is displayed when we use VS2017 to open the solution:
Disable VS2017 js
good News: Now we can debug node. js with our browser!!!Premise
node. js 6.3+, which can be downloaded on the node. JS website;
Chrome 55+. If your local chrome is upgraded to the latest version or
ConfigurationFor now, parallel debugging of JavaScript and node. js in the browser side is a new feature, a new experience. To be able to work properly, you need to configure the following:
JavaScript Print ControlsGitHub AddressHttps://github.com/DoersGuild/jQuery.printNeed to introduce jquery before use$ ("#mapDiv"). Print ({ globalstyles:true,//) contains the style of the parent document, and the default is True mediaprint:false,//contains the link label for media= ' print '. Is overridden by the
1 JavaScript printing can be controlled by style. If you want to print the block, the style is as follows: noprint {display: none} and then use the style: if you do not need to print a part of the web page, you just need to mark it as medium.
1. JavaScript Printing
You can use style control to
is very effective when you are debugging a web app's network transfer.
4. Mobile Device Simulation EnvironmentGoogle Chrome has some very interesting tools for simulating mobile devices that help us debug the operation of the program on mobile devices.The way to find it is: press F12, bring up the developer tool, and then press ESC (the current tab cannot be the console), you will see the Second
. Mobile Device Simulation EnvironmentGoogle Chrome has some very interesting tools for simulating mobile devices that help us debug the operation of the program on mobile devices.The way to find it is: press F12, bring up the developer tool, then press the ESC key (the current tab cannot be the console), you will see the Second Debug window appears, the inside of the Emulation tab has a variety of analog d
When you encounter a situation where you can't debug JavaScript code when submitting to a subpage, here's a good workaround, and hopefully it will help. In a recent project, you will not be able to debug JavaScript code when submitting to a child page, sometimes this problem, we can not normal in the browser, see our
The default script debugging is disabled. To enable it, you must:
Tools-> Internet Options... -> Advanced-> disable script debugging
On XP SP2, the options are split into two items:
Tools-> Internet Options... -> Advanced-> disable script debugging (Internet Explorer)Tools-> Internet Options... -> Advanced-> disable script debugging (other)
After you enable script debugging, the menu item 'view-> script debugger' will become visible. You can use it to break the file into the debugg
Javascript debug toolkit is an open-source and free Eclipse plug-in. Its official homepage is http://code.google.com/p/jsdt. a browser reference table supported by the tool is provided.
Tools/browsers
IE
Firefox
Safari
Chrome
Opera
Others
Vs.net
Supported
Microsoft Script Debugger
Supported
Firefox browsers, you can use the relevant debugger or plug-in to debug JavaScript.
● In Firefox, you can use the built-in "error console ". The procedure is as follows:Open the Firefox browser → In the menu bar "tools" → select "error console.Without other plug-ins, its built-in "error console" is a very good choice.
In addition, there are some good debuggers In the Firefox browser, such as Venkman an
Example of using firebug to debug javascript
There are many ways to debug javascript. This article describes how to use firebug. If you are interested, refer
The Code is as follows:
Debugging example
The Code is as follows:
Follow these steps:
(1) Open ie --> Internet Options --> advanced; remove the options on "Disable script debugging ".
(2) Open the page for debugging
(3) Start vs. Net IDE and select Tools-debug process (CTRL + ALT + p). Select the IE process to be debugged.
(4) Click the attach button and select the script option. then click OK to close the dialog box.
(5) Select the IDE menu debug à windows à runni
1. What is console?Console is a separate window used to display JS and DOM object information. And inject a console object to Js.You can output information to the console window.2. What browsers support console?Many people may know that chrome and Firefox support the console. Other browsers supportHold bad. For example, although the development tool provided by IE8 supports the console, its functions are monotonous and display objects.[Object, object], and you cannot click to view the attributes
In a recent project, you will not be able to debug JavaScript code when submitting to a child page, sometimes this problem, we can not normal in the browser, see our child page JavaScript code, so can only use the original alert or Console.log (), of course, this is a solution, but sometimes, we want to see how the program is actually running, but also can see wh
Javascript
A good way to debug JavaScript1, download Ms Script debugger and install from Microsoft website, this is the download address:Http://download.microsoft.com/download/winscript56/install/1.0a/NT45XP/EN-US/scd10en.exe
2, modify the settings of IE:IE option--> advanced, there are two options by default is the hook selected:Disable Script Debugging (Internet Explorer)Disable Script Debugging (Other)T
In general, the page for viewing html elements is first displayed.
2.3 click "script" on the top of the page.
Click "reload" to view the source code.
If no source code is displayed on this page, it indicates that there is a syntax error in the source code. You must modify the syntax error first. Common Errors include: unpaired parentheses, missing function return values, undefined variables, and case-insensitive errors.
You can use this function to detect syntax errors in the code.
[
In IE, you can see a "Dynamic Script" folder at the bottom of the debugger's document list, where you can find dynamically loaded scripts, but ... A large number of, can not customize the name ...But in Chrome, seemingly can't find the dynamic script, search the Web, found that can use //# sourceurl=xxx.js to customize the name of the dynamic script, very convenient!You can also use the format //# sourceurl=http://abc.com/xxx.js to classify different dynamic scripts with domain names and paths!A
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.