-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.js
More file actions
45 lines (44 loc) · 1.05 KB
/
eslint.config.js
File metadata and controls
45 lines (44 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
import globals from "globals";
import tseslint from "typescript-eslint";
import pluginReact from "eslint-plugin-react";
import hooks from "eslint-plugin-react-hooks";
import refresh from "eslint-plugin-react-refresh";
export default tseslint.config(
{
ignores: ["dist", "node_modules", "jupyter-books", "public"],
},
{
files: ["src/**/*.{ts,tsx}"],
plugins: {
react: pluginReact,
"react-hooks": hooks,
"react-refresh": refresh,
},
settings: {
react: {
version: "detect",
},
},
rules: {
...pluginReact.configs.flat.recommended.rules,
...pluginReact.configs.flat['jsx-runtime'].rules,
...hooks.configs.recommended.rules,
"react-refresh/only-export-components": "warn",
},
languageOptions: {
globals: {
...globals.browser,
},
parser: tseslint.parser,
parserOptions: {
project: "tsconfig.app.json",
},
},
},
{
files: ["src/components/ModelViewer.tsx"],
rules: {
"react/no-unknown-property": "off",
},
}
);