- Published on
Stop IntelliJ Constantly Indexing for a NodeJS Project
- Authors
- Name
- Yair Mark
- @yairmark
I have been doing quite a bit of work in React in the last few days. For this work, I used IntelliJ as I am most comfortable with it as an IDE and the work is sufficiently heavy enough to warrant the use of an IDE.
Today I was doing quite a bit of work in React. I had a dev server running and was making changes and seeing the changes live. The one thing which was driving me nuts was every change I made in the IDE resulted in IntelliJ trying to index. This indexing seemed to be constant. This often resulted in the IDE freezing up or not freezing but then the IDE had no intellisense. In a nutshell, if this problem persisted I would have been better off with a much lighter editor as I was not getting any of the benefits of the IDE/
I see a bunch of people have this issue - not always for NodeJS, but it is still clearly an issue.
In the end, I worked out that it must be my dist
folder that was causing it to index. This only happened when I was running a dev server which would change the contents of dist
to transpile and reflect the changes I made. As I do not need dist at all for intellisense purposes, I simply went into IntelliJ, right-clicked the dist
folder, chose Mark Directory as
and chose Excluded
. Voila, it worked! No more annoying constant indexing and I can live edit in peace.