Skip to content

Commit

Permalink
Update eslint-plugin-import
Browse files Browse the repository at this point in the history
2.28.0 introduced a breaking change to `import/order` where the order
of nested groups (whose purpose is to define different types of imports
that are of equivalent rank) started to matter: a single nested group
would be treated as though it wasn't nested

We [got around this][1] by adding a second nested group with most if
not all of the other import types we use

It looks like #141
brought us back to 2.27.5. If we go back to 2.28.0 now and revert to
the simpler config, for some reason the ESLint errors don't reappear

In any case, I submitted a [bug fix][2] in eslint-plugin-import 💅
This was released in 2.28.1, so we should upgrade, hopefully preventing
an unexpected return to confusing errors

[1]: ab5a73e
[2]: import-js/eslint-plugin-import#2854
  • Loading branch information
yndajas committed Aug 31, 2023
1 parent ab8a4cd commit 47bf31b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
5 changes: 1 addition & 4 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,7 @@
"error",
{
"alphabetize": { "order": "asc", "orderImportKind": "asc" },
"groups": [
["builtin", "external"],
["internal", "parent", "sibling"]
],
"groups": [["builtin", "external"]],
"newlines-between": "always"
}
],
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
"eslint-config-prettier": "^9.0.0",
"eslint-import-resolver-typescript": "^3.5.5",
"eslint-plugin-cypress": "^2.13.2",
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-import": "^2.28.1",
"eslint-plugin-no-only-tests": "^3.1.0",
"eslint-plugin-prettier": "^5.0.0",
"eslint-plugin-sort-exports": "^0.8.0",
Expand Down

0 comments on commit 47bf31b

Please sign in to comment.