Mark Directory As... Follow
In an attempt to speed up indexing, I attempted to exclude the node_modules library root (this is from Angular CLI). Now the app doesn't work because it "cannot find module systemjs-builder." This is a directory within the node_modules library root. When excluding other directories, I can un-exclude them by right-clicking on them and selecting "Mark Directory As...Cancel Exclusion." There is no such option when I right-click on node_modules library root any more. In fact, there is no "Mark Directory As..." at all any more. What have I done and how can I fix it? The code is here: https://github.com/mrmikemcguire/NG2-Udemy-CLI.
Please sign in to leave a comment.
Un-excluding node_modules works fine for me. Please can you provide a screenshot that shows up the issue (missing "Mark Directory As..." ) plus your idea.log?
Wow, Elena, you're so quick to respond to concerns - thank you! Here's the screenshot:
As far as the idea.log file, where would I find that? This folder is not inside my WebStorm Projects folder. I downloaded the Angular CLI and have been using WebStorm to manipulate that file; I didn't create it in WebStorm.
Any idea how to fix this? Can you get the application to run?
I un-excluded everything except the tmp file, but the project is still reporting that it can't find systemjs-builder, I don't believe anything else has changed since the application was last working. Here's the screenshot:
It can't have any relation to excluding folders/setting up libraries, it must be a problem with your project setup that can't be resolved on IDE side...
Excluding a folder only affects indexing (completion/type hinting/etc.) in WebStorm. It has absolutely on impact on running your application
Your project works for me:
Was the original concern addressed:
In fact, there is no "Mark Directory As..." at all any more
I'm having the same problem with my node_modules directory
Hello, I'm having a similar issue, I opened https://intellij-support.jetbrains.com/hc/en-us/community/posts/208376385-How-to-unexclude-node-modules-in-2016-2-2- to discuss.
Thanks for any ideas.
We have a similar problem with the "dist" directory being auto-excluded and unable to unexclude it.
Only on certain projects though, which makes me suspect its doing some kind of (wrong) heuristic to decide whether it should be excluded or not - which of course is why you need to be able to override things !
It looks like the issue is the webpack.conf which specifies dist as the output path.
I understand why that makes sense to auto-ignore the dist file, BUT not allowing it to be overridden is just painful, especially with no way to understand WHY it won't allow you to do it.
The workaround seems to be ... delete your webpack.config file, and open the project, then you can restore it once the project is open (painful!), do this each time you start webstorm
BTW, can you check if the issue persist in 2018.2 EAP? https://youtrack.jetbrains.com/issue/WEB-33007 fix should make the auto-exclusion more smart
I don't have 2018.2, only 2018.1.4
I think the problem is not solved by making the auto-exclusion smarter, it would be solved by
a) making WebStorm's choices visible - how many other people have struggled for hours before stumbling upon the right forum post trying to figure out why some directories can be Unexcluded and other's can't. At the very least when I try and unexclude it, there should have been a message that says so, rather than an absence of UI. This kind of unreported "smart" behavior is one of the annoyances of WebStorm that I've encountered before.
b) Never making "smart" decisions without giving us a (findable) way to override them when - as is inevitable - we encounter cases where the "smarts" get it wrong.
This wasted a good couple of hours of crucial development time yesterday (first finding this post, and then figuring out that it was this obscure line in the webpack config to change), and I'm sure everyone else reporting similar bugs has wasted similar amounts of time. If each developer hits one or two of these kinds of things, then that more than balances any savings by WebStorm being "smart" and obscure.
OK, we'll add a notification about this in 2018.2