Skip to content

Commit

Permalink
build: add eslint.config file
Browse files Browse the repository at this point in the history
  • Loading branch information
SomethingSexy committed Oct 28, 2024
1 parent 89e8678 commit 94b86c8
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import js from "@eslint/js";
import reactHooks from "eslint-plugin-react-hooks";
import reactRefresh from "eslint-plugin-react-refresh";
import tsEslint from "typescript-eslint";
import tsParser from "@typescript-eslint/parser";

export default [
js.configs.recommended,
...tsEslint.configs.recommended,
{
files: ["**/*.ts", "**/*.tsx", "**/*.js"],
plugins: {
"react-refresh": reactRefresh,
"react-hooks": reactHooks,
},
languageOptions: {
parser: tsParser,
},
rules: {
"react-refresh/only-export-components": [
"warn",
{ allowConstantExport: true },
],
"sort-imports": "error",
},
},
];

0 comments on commit 94b86c8

Please sign in to comment.