Skip to content

Commit

Permalink
Bring back eslint-plugin-import
Browse files Browse the repository at this point in the history
  • Loading branch information
be5invis committed Oct 12, 2024
1 parent 1666e2b commit 1b7ad7c
Show file tree
Hide file tree
Showing 21 changed files with 910 additions and 34 deletions.
15 changes: 15 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import globals from "globals";
import js from "@eslint/js";
import eslintPluginPrettierRecommended from "eslint-plugin-prettier/recommended";
import importPlugin from "eslint-plugin-import";

export default [
js.configs.recommended,
eslintPluginPrettierRecommended,
importPlugin.flatConfigs.recommended,

// Ignore machine-generated files
{
Expand Down Expand Up @@ -37,6 +39,19 @@ export default [
"no-mixed-spaces-and-tabs": ["error", "smart-tabs"],
"no-unused-vars": ["off"],
complexity: ["warn", 16],

// eslint-import rules
"import/no-unresolved": "off", // ESLint does not support subpath exports, but we do
"import/no-extraneous-dependencies": "error",
"import/newline-after-import": ["error", { count: 1 }],
"import/order": [
"error",
{
groups: ["builtin", "external", "internal", "parent", "sibling", "index"],
"newlines-between": "always",
alphabetize: { order: "asc", caseInsensitive: true },
},
],
},
},
];
Loading

0 comments on commit 1b7ad7c

Please sign in to comment.