|
10 | 10 | "plugin:prettier/recommended", |
11 | 11 | "plugin:react-hooks/recommended", |
12 | 12 | "plugin:import/errors", |
13 | | - "plugin:import/warnings" |
| 13 | + "plugin:import/warnings", |
| 14 | + "plugin:storybook/recommended" |
| 15 | + ], |
| 16 | + "plugins": [ |
| 17 | + "@typescript-eslint", |
| 18 | + "react", |
| 19 | + "prettier", |
| 20 | + "react-hooks", |
| 21 | + "import" |
14 | 22 | ], |
15 | | - "plugins": ["@typescript-eslint", "react", "prettier", "react-hooks", "import"], |
16 | 23 | "parser": "@typescript-eslint/parser", |
17 | 24 | "parserOptions": { |
18 | 25 | "ecmaVersion": 2018, |
|
21 | 28 | "jsx": true |
22 | 29 | }, |
23 | 30 | "rules": { |
24 | | - "curly": ["warn", "multi-line", "consistent"], |
| 31 | + "curly": [ |
| 32 | + "warn", |
| 33 | + "multi-line", |
| 34 | + "consistent" |
| 35 | + ], |
25 | 36 | "no-console": "off", |
26 | 37 | "no-empty-pattern": "warn", |
27 | 38 | "no-duplicate-imports": "error", |
28 | | - "import/no-unresolved": ["error", { "commonjs": true, "amd": true }], |
| 39 | + "import/no-unresolved": [ |
| 40 | + "error", |
| 41 | + { |
| 42 | + "commonjs": true, |
| 43 | + "amd": true |
| 44 | + } |
| 45 | + ], |
29 | 46 | "import/export": "error", |
30 | | - // https://github.com/typescript-eslint/typescript-eslint/blob/master/docs/getting-started/linting/FAQ.md#eslint-plugin-import |
31 | | - // We recommend you do not use the following import/* rules, as TypeScript provides the same checks as part of standard type checking: |
32 | 47 | "import/named": "off", |
33 | 48 | "import/namespace": "off", |
34 | 49 | "import/default": "off", |
35 | 50 | "@typescript-eslint/explicit-module-boundary-types": "off", |
36 | | - "no-unused-vars": ["warn", { "argsIgnorePattern": "^_", "varsIgnorePattern": "^_" }], |
37 | | - "@typescript-eslint/no-unused-vars": ["warn", { "argsIgnorePattern": "^_", "varsIgnorePattern": "^_" }], |
| 51 | + "no-unused-vars": [ |
| 52 | + "warn", |
| 53 | + { |
| 54 | + "argsIgnorePattern": "^_", |
| 55 | + "varsIgnorePattern": "^_" |
| 56 | + } |
| 57 | + ], |
| 58 | + "@typescript-eslint/no-unused-vars": [ |
| 59 | + "warn", |
| 60 | + { |
| 61 | + "argsIgnorePattern": "^_", |
| 62 | + "varsIgnorePattern": "^_" |
| 63 | + } |
| 64 | + ], |
38 | 65 | "@typescript-eslint/no-use-before-define": "off", |
39 | 66 | "@typescript-eslint/no-empty-function": "off", |
40 | 67 | "@typescript-eslint/no-empty-interface": "off", |
|
45 | 72 | "react": { |
46 | 73 | "version": "detect" |
47 | 74 | }, |
48 | | - "import/extensions": [".js", ".jsx", ".ts", ".tsx"], |
| 75 | + "import/extensions": [ |
| 76 | + ".js", |
| 77 | + ".jsx", |
| 78 | + ".ts", |
| 79 | + ".tsx" |
| 80 | + ], |
49 | 81 | "import/parsers": { |
50 | | - "@typescript-eslint/parser": [".js", ".jsx", ".ts", ".tsx"] |
| 82 | + "@typescript-eslint/parser": [ |
| 83 | + ".js", |
| 84 | + ".jsx", |
| 85 | + ".ts", |
| 86 | + ".tsx" |
| 87 | + ] |
51 | 88 | }, |
52 | 89 | "import/resolver": { |
53 | 90 | "node": { |
54 | | - "extensions": [".js", ".jsx", ".ts", ".tsx", ".json"], |
55 | | - "paths": ["src"] |
| 91 | + "extensions": [ |
| 92 | + ".js", |
| 93 | + ".jsx", |
| 94 | + ".ts", |
| 95 | + ".tsx", |
| 96 | + ".json" |
| 97 | + ], |
| 98 | + "paths": [ |
| 99 | + "src" |
| 100 | + ] |
56 | 101 | }, |
57 | 102 | "alias": { |
58 | | - "extensions": [".js", ".jsx", ".ts", ".tsx", ".json"], |
59 | | - "map": [["@react-three/postprocessing", "./src/index.tsx"]] |
| 103 | + "extensions": [ |
| 104 | + ".js", |
| 105 | + ".jsx", |
| 106 | + ".ts", |
| 107 | + ".tsx", |
| 108 | + ".json" |
| 109 | + ], |
| 110 | + "map": [ |
| 111 | + [ |
| 112 | + "@react-three/postprocessing", |
| 113 | + "./src/index.tsx" |
| 114 | + ] |
| 115 | + ] |
60 | 116 | } |
61 | 117 | } |
62 | 118 | }, |
63 | 119 | "overrides": [ |
64 | 120 | { |
65 | | - "files": ["src"], |
| 121 | + "files": [ |
| 122 | + "src" |
| 123 | + ], |
66 | 124 | "parserOptions": { |
67 | 125 | "project": "./tsconfig.json" |
68 | 126 | } |
|
0 commit comments