Minor: Do not clear the config cache on each run #368
Merged
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.
Fixes #304
This halfs the time taken on CLI runs. However when you make a config
change your editor won't pick up that change until you reload your
editor window (either by restarting your editor, or in VSCode there is a
"Reload window" command).
Given that most of the time you're not adjusting your config, this
speedup is worth that extra bit of friction.
After this change your editor's eslint plugin will not instantly pick up config changes in
.prettierrc. I suggest moving your prettier config into package.json - which eslint plugins should already be watching as it may effect eslint configuration changes. Worst case scenario you'll need to restart your editor after changing your prettier configuration.On my test repo, getting timing info by running
TIMING=1 yarn run eslint .: Without this change the prettier/prettier rule takes ~19s, with this change it takes ~8.5s.