Recently I have faced a problem with opening in Visual Studio a project that contains npm packages folder. My npm packages are placed in the folder “node_modules” inside my VS project and evidently VS is unable to read this directory(after update VS13 upd4). I believe this is because the directory might have very deep path for one of the packages.
I did try to reinstall VS13 and even installed VS15 but it didn’t help.
The obvious solution is to exclude “node_modules” folder from the project BUT apparently it is impossible to do in VS for website-type project. Another solution is to move “node_modules” folder up in hierarchy so it would be next to your project folder but I need to keep npm packages locally and use specific and not the latest versions of some packages.
Finally I discovered that if you mark “node_modules” folder as hidden VS will not index this folder which is the easiest solution to my problem.
I did try to reinstall VS13 and even installed VS15 but it didn’t help.
The obvious solution is to exclude “node_modules” folder from the project BUT apparently it is impossible to do in VS for website-type project. Another solution is to move “node_modules” folder up in hierarchy so it would be next to your project folder but I need to keep npm packages locally and use specific and not the latest versions of some packages.
Finally I discovered that if you mark “node_modules” folder as hidden VS will not index this folder which is the easiest solution to my problem.
No comments:
Post a Comment