diff options
author | Kristóf Marussy <kristof@marussy.com> | 2022-08-12 19:54:46 +0200 |
---|---|---|
committer | Kristóf Marussy <kristof@marussy.com> | 2022-08-12 19:54:46 +0200 |
commit | d22c3b0c257f5daf5b401988a35ab9ce981a2341 (patch) | |
tree | 0a661c927c37b52197326d1c05e211daf9bd19e5 /subprojects/frontend/.eslintrc.js | |
parent | fix(language): rule parsing test (diff) | |
download | refinery-d22c3b0c257f5daf5b401988a35ab9ce981a2341.tar.gz refinery-d22c3b0c257f5daf5b401988a35ab9ce981a2341.tar.zst refinery-d22c3b0c257f5daf5b401988a35ab9ce981a2341.zip |
refactor(frontend): move from Webpack to Vite
Also overhaulds the building and linting for frontend assets.
Diffstat (limited to 'subprojects/frontend/.eslintrc.js')
-rw-r--r-- | subprojects/frontend/.eslintrc.js | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/subprojects/frontend/.eslintrc.js b/subprojects/frontend/.eslintrc.js deleted file mode 100644 index aa7636f8..00000000 --- a/subprojects/frontend/.eslintrc.js +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | // Loosely based on | ||
2 | // https://github.com/iamturns/create-exposed-app/blob/f14e435b8ce179c89cce3eea89e56202153a53da/.eslintrc.js | ||
3 | module.exports = { | ||
4 | plugins: [ | ||
5 | '@typescript-eslint', | ||
6 | ], | ||
7 | extends: [ | ||
8 | 'airbnb', | ||
9 | 'airbnb-typescript', | ||
10 | 'airbnb/hooks', | ||
11 | 'plugin:@typescript-eslint/recommended', | ||
12 | 'plugin:@typescript-eslint/recommended-requiring-type-checking', | ||
13 | ], | ||
14 | parserOptions: { | ||
15 | project: './tsconfig.json', | ||
16 | }, | ||
17 | rules: { | ||
18 | // https://basarat.gitbooks.io/typescript/docs/tips/defaultIsBad.html | ||
19 | 'import/prefer-default-export': 'off', | ||
20 | 'import/no-default-export': 'error', | ||
21 | // propTypes are for runtime validation, but we rely on TypeScript for build-time validation: | ||
22 | // https://github.com/yannickcr/eslint-plugin-react/issues/2275#issuecomment-492003857 | ||
23 | 'react/prop-types': 'off', | ||
24 | // Make sure switches are exhaustive: https://stackoverflow.com/a/60166264 | ||
25 | 'default-case': 'off', | ||
26 | '@typescript-eslint/switch-exhaustiveness-check': 'error', | ||
27 | // https://github.com/airbnb/javascript/pull/2501 | ||
28 | 'react/function-component-definition': ['error', { | ||
29 | namedComponents: 'function-declaration', | ||
30 | }], | ||
31 | }, | ||
32 | env: { | ||
33 | browser: true, | ||
34 | }, | ||
35 | ignorePatterns: [ | ||
36 | '*.js', | ||
37 | 'build/**/*', | ||
38 | ], | ||
39 | }; | ||