Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request
Problem
We were installing
standard
, but then runningeslint
and trying to access its dependency configuration files rather than depending on their packages explicitly. This is fragile.standard
cli not usable because of custom eslint rules.The TypeScript config was not using
standard
base configuration due to previous annoyance with the multiple dependencies.Solution
Install
standard
ESLint configurations and not the whole package. Install necessary peer dependencies, so works with npm below npm 8 which require explicitly installing peer dependencies. Basically same dependencies foreslint-config-standard
andeslint-config-standard-with-typescript
so go back to usingstandard
for TypeScript too.Used
eslint --fix
to fix most of the problems picked up. Nice, don't needstandard
CLI to get--fix
!The downside is we still have to juggle dependencies when some
standard
dependencies lag behind versions of ESLint or TypeScript, like currently still waiting for one last package (eslint-plugin-node
) to get ESLint 8 support.Considered another approach but rejected: switch to using
semistandard
andts-standard
instead ofeslint
. Reasons:semistandard
there is nots-semistandard
standard
, but not sure if can work with bothsemistandard
andts-standard
standard
is no configurationChangeLog
standard
relateddevDependencies
and usage