with tsconfig.json
:
{
"compilerOptions": {
"experimentalDecorators": true,
"target": "es2017",
"allowJs": true,
"moduleResolution": "node",
"noEmitOnError": false,
"noEmit": true,
"sourceMap": true,
"baseUrl": ".",
"module": "es6",
"paths": {
"npm:asn1js": [ "node_modules/asn1js" ],
}
},
"exclude": [
"tmp",
"dist",
"node_modules"
]
}
with tslint.json
configuration:
{
"extends": [
"tslint:recommended"
]
}
Running
$ node_modules/.bin/tslint --project tsconfig.json
I get
ERROR: /code/my_project/node_modules/asn1js/build/asn1.js[8, 5]: variable name must be in lowerCamelCase, PascalCase or UPPER_CASE
ERROR: /code/my_project/node_modules/asn1js/build/asn1.js[8, 55]: if statements must be braced
ERROR: /code/my_project/node_modules/asn1js/build/asn1.js[10, 5]: variable name must be in lowerCamelCase, PascalCase or UPPER_CASE
ERROR: /code/my_project/node_modules/asn1js/build/asn1.js[10, 233]: if statements must be braced
...
I expect tslint to obey the exclude: [ "node_modules" ]
. If I remove the "npm:asn1js"
entry from paths
, I get no tslint errors.
I've also tried
// tsconfig.json
{
"exclude": [
"node_modules",
"node_modules/**/*.{j,t}s"
]
}
and
// tsconfig.json
{
"linterOptions": {
"exclude": [
"node_modules/**/*.{j,t}s"
]
}
}
to no avail.
If I run
node_modules/.bin/tslint --project tsconfig.json --exclude "node_modules/**/*.{j,t}s"
it works great.
TSLint is being deprecated and no longer accepting pull requests for major new changes or features. See #4534. 😱
If you'd like to see this change implemented, you have two choices:
👋 It was a pleasure open sourcing with you!
_If you believe this message was posted here in error, please comment so we can re-open the issue!_
🤖 Beep boop! 👉 TSLint is deprecated 👈 _(#4534)_ and you should switch to typescript-eslint! 🤖
🔒 This issue is being locked to prevent further unnecessary discussions. Thank you! 👋
Most helpful comment
I've also tried
and
to no avail.
If I run
it works great.