【ask】webstorm调试node单个js文件
The procedure falls into two parts: first we start an application as usual and then connect to it with the debugger.
- Set the breakpoints in the Node.js code, where necessary. At least one breakpoint is necessary otherwise the program will be just executed. If you want the debugging tool to stop at the first line of your code, set a breakpoint at the first line.

- Create a Node.js run configuration with the following option in the Node parameters text box: --debug-brk==<port for connect to debugger remotely>
Note

- The --debug-brk option allows you to debug the code executed on start.
- The --debug option is useful when you are not going to debug Node.js right now, but you want to debug it later.
- Run the application with the created configuration.

- Create a Node.js Remote Debug configuration: in the Debug port text box, type the port number specified in the currently running Node.js configuration.

- With the application still running, launch the Node.js Remote Debug configuration (select the configuration in the list and click the Debug toolbar button
).
- In the Run tool window, copy the URL address of the server and open the corresponding page in the browser. Control over the debugging session returns to WebStorm.
- Switch to WebStorm. In the Debug tool window, step through the breakpoints, switch between frames, change values on-the-fly, examine a suspended program, evaluate expressions, and set watches.
【ask】webstorm调试node单个js文件的更多相关文章
- 针对单个 js 文件禁用 ESLint 语法校验
问题描述: 在 Vue-cli 创建的项目中,使用了 ESLint 规范代码的项目中 如何针对单个 js 文件禁用 ESLint 语法校验,但整个项目依然保留 ESLint 的校验规则? 解决方案: ...
- 使用webstorm调试node程序
前言 相信大家接触过不少node代码了,如果你应用的比较初级或者针对你的项目不需要接触过深的node代码,也许你仅仅需要简单的console.log('your variable')就完全满足你的需要 ...
- vue项目引入第三方js插件,单个js文件引入成功,使用该插件方法时报错(问题已解决)
1.引入第三方js文件,npm安装不了 2.控制台显示引入成功 3.在methods下使用 图片看不清请看下面代码 updateTime() { setInterval(()=>{ var cd ...
- 使用webstorm调试node.js
折腾半天,还是webstorm顺手,但也遇到一些小问题. 1.代码补全问题 nodeJS自身的补全 File->Project Setting->JavaScript->Librar ...
- WebStorm调试node.js
直接上图:
- webstorm 设置uglify 压缩js文件
第一步:打开npm,全局安装 npm install uglify-js -g 第二步: 打开webstorm的file->settings ->External Tools,点击左上角的 ...
- webstorm调试Node的时候配置
点击Edit Configurations的这个的配置:(不能点击是因为目前你选中的不是项目)
- 单个 js 文件禁用 ESLint 语法校验
在代码顶部添加一行注释 /* eslint-disable */ ESLint 在校验的时候就会跳过后面的代码 还可以在注释后加入详细规则,这样就能避开指定的校验规则了 /* eslint-disab ...
- 如何调试异步加载的js文件(浏览器调试动态加载js)
描述 1:jQuery->var obj= new $.js_Obj():等异步加载js文件,执行方法. obj.method(): 2:页面估计不变,通过声明不同的js文件,进行页面内容的转换 ...
随机推荐
- Modify Headers模拟不同地域进行网页测试
今天要简单讲一下Modify Headers这个Firefox插件,记录一下我是怎么使用它的. Modify Headers: https://addons.mozilla.org/zh-CN/fir ...
- 基础普及-Jar、War、Ear
名词解释 Jar文件(扩展名为. Jar) 包括Java类的普通库.资源(resources).辅助文件 (auxiliary files)等 War文件(扩展名为.War) 包括所有Web应用程序. ...
- LintCode - Merge Two Sorted List
LintCode - Merge Two Sorted Lists LintCode - Merge Two Sorted Lists Web Link Description Code - C Ti ...
- Vue 组件开发demo
1.代码地址 github:https://github.com/MengFangui/VueComponentDemo- 2.关键代码 (1)main.js //引入vue import Vue f ...
- 【DB2】NOT IN使用中的大坑
1.环境准备 ------建表TB DROP TABLE TB; CREATE TABLE TB ( ID INTEGER, LEVEL_DETAIL ) ); INSERT INTO TB (ID, ...
- iOS开发-在Swift里使用AFNetworking方法
在OC里使用惯了AFNetworking,比较喜欢这一个第三方库,在别的途径里得知可以在Swift里使用AFNetworking.但是那个时候我不知道具体的操作是怎样的,于是我只能去百度.GOOGLE ...
- 软件质量特征 ISO9126
ISO/IEC9126软件质量模型是一种评价软件质量的通用模型,包括3个层次: 1.质量特性 2.质量子特性 3.度量指标 其中各六个质量特性与二十七个质量子特性的关系如下表: 1.功能性 是指当软件 ...
- .Net基础——程序集与CIL HttpClient封装方法 .Net Core 编码规范 C#中invoke和beginInvoke的使用 WebServeice 动态代理类
.Net基础——程序集与CIL 1. 程序集和CIL: 程序集是由.NET语言的编译器接受源代码文件产生的输出文件,通常分为 exe和dll两类,其中exe包含Main入口方法可以双击执行,dll ...
- src和href使用总结
src img 图片 <img src="/img/1.png" alt="1" /> rame iframe 框架集 <iframe src ...
- 一个文件查看你选择 Run as Android applications 都干了啥
<?xml version="1.0" encoding="UTF-8"?> <project name="PushFastDemo ...