I am using WebStorm to run a grunt task. The debugger successfully stops at the breakpoint in the Gruntfile.js file, but not in my task file.
In the Gruntfile.js I regis
To run grunt task in debug, you need to pass the grunt task script to node-inspector:
node-debug $(Path \AppData\Roaming\npm\node_modules\grunt-cli\bin\grunt) task
Put a debugger;
line in your task. node-inspector
will then open a browser with debugging tools.
This link help you how its work grunt-node-inspector
Example: ChrisWren/grunt-node-inspector
Source: Stackoverflow Question