-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy path.eslintrc.cjs
31 lines (30 loc) · 1006 Bytes
/
.eslintrc.cjs
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
// eslint-disable-next-line @typescript-eslint/no-var-requires
const config = require('./.prettierrc.cjs');
/** @type {import('eslint').Linter.Config} */
module.exports = {
parser: '@typescript-eslint/parser',
extends: ['plugin:react/recommended', 'plugin:@typescript-eslint/recommended', 'plugin:prettier/recommended', 'prettier', '@remix-run/eslint-config', '@remix-run/eslint-config/node', 'plugin:storybook/recommended'],
plugins: ['@typescript-eslint', 'html', 'jsx-a11y'],
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
ecmaFeatures: {
jsx: true, // Allows for the parsing of JSX
},
},
settings: {
react: {
version: 'detect', // Tells eslint-plugin-react to automatically detect the version of React to use
},
},
rules: {
'prettier/prettier': ['error', config],
'@typescript-eslint/consistent-type-imports': [
'error',
{
prefer: 'type-imports',
disallowTypeAnnotations: true,
},
],
},
};