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.
In this PR, I set up a proper linting & formatting of our TypeScript code via ESLint and the amazing ESLint Stylistic. Please explore these rules and see the effects for our files as I will open a new PR as follow-up which lints our entire codebase based on the autofixes provided by ESLint. You might have to click on
Spaces: 2
in VSCode for linted files (bottom right corner) if it doesn't automatically recognize it.The linting is mainly such that we have a consistent code style since I don't like to discuss purely stylistic preferences in PRs and want to use the power of ESLint to see if I didn't use variables, didn't conform to normal naming of variables etc.
I also add ESLint to a GitHub Actions pipeline such that in every PR, we get direct feedback here on GitHub (for only the changed files of the PR).
I've also upgraded the npm modules (we only have
dev
modules).Tip
You have to run
npm install
again to fetch the upgraded dependencies. Otherwise, ESLint will probably not work for you.