There was a nice example in google groups of using VS Code to debug a running node-red server from Julian earlier this year...
But if you have a local install of node-red-dashboard
, and you "compile" it with gulp, but are seeing no changes when you reload the browser, then it sounds like your node-red server is not running with the local installed version. (I put "compile" in quotes, since nodejs is not compiled -- gulp is just packaging up all the html pages and js bits into files that the browser can digest).
One other trick I use to get non-minified .js files into the browser is (very briefly) described under the Developers section at the bottom of the dashboard homepage. Turns out that you can either delete the entire dist
directory after running gulp, or just the index.html page that was generated. When the dashboard detects that page is missing, it uses the un-minified versions of the javascript files, so it's easier to step through them in the browser's dev console (F12). You should see something like this in your startup log, when it's set up properly:
Welcome to Node-RED
===================
13 Jul 11:49:46 - [info] Node-RED version: v0.18.7-git
13 Jul 11:49:46 - [info] Node.js version: v8.11.2
13 Jul 11:49:46 - [info] Windows_NT 10.0.17134 x64 LE
13 Jul 11:49:47 - [info] Loading palette nodes
13 Jul 11:50:01 - [info] Dashboard version 2.9.5 started at /red/ui
13 Jul 11:50:05 - [warn] ------------------------------------------------------
13 Jul 11:50:05 - [warn] [node-red/rpi-gpio] Info : Ignoring Raspberry Pi specific node
13 Jul 11:50:05 - [warn] [node-red/tail] Not currently supported on Windows.
13 Jul 11:50:05 - [warn] ------------------------------------------------------
13 Jul 11:50:05 - [info] Settings file : C:\NODE\node_red_ui\settings.js
13 Jul 11:50:05 - [info] HTTP Static : C:\NODE\node_red_ui\public
13 Jul 11:50:05 - [info] User directory : C:\NODE\node_red_ui
13 Jul 11:50:05 - [warn] Projects disabled : editorTheme.projects.enabled=false
13 Jul 11:50:05 - [info] Flows file : C:\NODE\node_red_ui\flows_ENTLAPTOP18.json
13 Jul 11:50:05 - [info] [Dashboard] Dashboard using development folder
13 Jul 11:50:05 - [info] Server now running at http://127.0.0.1:18806/admin/
Notice that second to last line... If you are not seeing that, then check that your npm link in your .node-red/node_modules
directory is pointing to your local install of the dashboard.