refactor: updated eslint devDepencencies
Summary of changes:
It's important that someone else with ESLint, babel and webpack knowledge would have a look at these changes, especially my three code comments and the necessary evaluations.
- Updated all eslint and related dependencies to newer versions and
- extracted the eslintconfig within the
live-serverpackage to an external config file
added
-
eslint-plugin-node:
- Two of the previously introduced eslint rules have been moved to this plugin by ESLint v7.0.0:
-
no-mixed-requires->node/no-mixed-requires -
no-process-exit->node/no-process-exit
-
- Two of the previously introduced eslint rules have been moved to this plugin by ESLint v7.0.0:
-
@babel/eslint-plugin
Companion rules for
@babel/eslint-parser.@babel/eslint-parserdoes a great job at adaptingeslintfor use with Babel, but it can't change the built-in rules to support experimental features.@babel/eslint-pluginre-implements problematic rules so they do not give false positives or negatives.
updated dependencies
- eslint
- ~~eslint-plugin-import~~
- ~~eslint-config-airbnb-base~~
-
eslint-plugin-prettier
- [x] This breaking change drops support for old versions of ESLint, Prettier and Node. You must use at least ESLint v7.28.0, Prettier v2.0.0 and Node v12.0.0. Aside from that, usage of this plugin remains identical. We're matching the ESLint version with the updates from this pull request and Prettier even already, as well as Node.
- eslint-config-prettier
replaced
- "
babel-eslintis now@babel/eslint-parser.", source https://www.npmjs.com/package/babel-eslint and https://babeljs.io/blog/2020/07/13/the-state-of-babel-eslint
Changed
rules
- Replaced deprecated and removed rules by
ESLint@7: https://eslint.org/docs/rules/#deprecated (seeaddedsection above as well)
extends
-
https://github.com/prettier/eslint-plugin-prettier#recommended-configuration:
This plugin ships with a
plugin:prettier/recommendedconfig that sets up both the plugin andeslint-config-prettierin one go.and read further on the section
Exactly what does plugin:prettier/recommended do? Well, this is what it expands to:
ESLint and babel configs
sub-packages ESLint config file with an extend to root isn't necessary, as ESLint would search for that config anyhow, but we need to reference the root babel.config.js in our monorepo, compare to e.g.
https://babeljs.io/docs/en/config-files#root-babelconfigjson-file and https://babeljs.io/docs/en/config-files#file-relative-configuration
pending
- ~Why do we have both a
.eslintrc.jsand a.eslintrc.jsonin the root?~
Somehow this one does not want to deploy to our preview systems 😟
who has access to the logs and could probably shed some light on what‘s happening there and any error log messages?
I think @sghoweri has access