3

I was trying to use the TODO window from WebStorm (or any other JetBrains IDE), but I get tons of TODOs from node_modules:

So in this way, this feature is not really useful. When I exclude the node_modules folder from the project, the TODOs go away, but also the autocompletion from those modules etc, so I don't think this is really the way to go.

How can I make sure those TODOs from node_modules are not shown?

LazyOne
  • 158,824
  • 45
  • 388
  • 391
Kasper
  • 12,594
  • 12
  • 41
  • 63
  • Sure: 1) Create custom Scope and list there only real project files 2) use that scope in TODO window (instead of "Project Files"). Check these SO questions: http://stackoverflow.com/a/14901722/783119 ; http://stackoverflow.com/a/34614431/783119 – LazyOne Jul 22 '16 at 19:29

2 Answers2

2

For a solution if it didn't get fixed by magic (I assume plugin did that for your case) :

  • Press Alt + 6 (default bind for TODO)
  • Click on "Scope based" tab
  • Change the "Scope" by clicking on the button with three dot
  • Choose what directory you want to exclude in recursive way or not.
  • ???
  • Enjoy
0

It seemed like Webstorm fixed this itself after restarting Webstorm, I saw my node_modules where listed as 'library root'. I suppose this is a bug where node_modules are not listed as library on creating a new project.

Kasper
  • 12,594
  • 12
  • 41
  • 63