atom-ternjs
atom-ternjs copied to clipboard
dontLoad is broken with loadEagerly
I'm trying to exclude node_modules from being indexed as it's ridiculously expensive.
{
"ecmaVersion": 6,
"libs": [],
"dontLoad": [
"**/node_modules/**"
],
"loadEagerly": [
"**/*.js"
],
"plugins": {
"node": {},
"modules": {},
"es_modules": {},
"doc_comment": {
"fullDocs": true
}
}
}
With this it should exclude them. I've even tested it using the glob library used by this project, minimatch
.
require('minimatch')('someRandomDir/node_modules/acorn-jsx/node_modules/acorn/bin/build-acorn.js', '**/node_modules/**')
// true
https://tonicdev.com/5737d10ea492941100e022cd/5737d11f8b73ef1200612059
When I run ternjs listfiles, I get node_modules in the results (40k files).
I've had a look at the code and don't really get why it's not working, either.
Even when I have:
"dontLoad": [
"src/*.js"
],
"loadEagerly": [
"src/*.js"
],
I get a files output of
{ files: [ "src/JsonbBuilder.js" ] }
Which makes no sense