This repository was archived by the owner on Jan 20, 2022. It is now read-only.
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.
We have more people contributing to this library now, so adding some
automated consistency is looking more and more important.
Also, this found a few unused variables, which highlighted a bug, albeit
a harmless one: a timer string was being created, but then no timer
being attached to Shrinkwrap loading. (That's why the reify snapshot is
updated.) Some other light refactoring was done in a few places to get
eslint to produce a reasonably readable output, and I think mostly for
the improvement of readability.
I don't 100% agree with every choice the linter is making here.
Specifically, I prefer using {} around single-line blocks in some cases,
especially loops, but they are omitted most of the time, so that's the
way I set the config. Consistency is good though, and this will help us
maintain it.
Linting is set up as a posttest operation, so we can catch things
without having it stubbornly refuse to even run tests until it's all
sparkling.
References