-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
42 lines (41 loc) · 1.02 KB
/
.eslintrc.js
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
module.exports = {
parser: '@typescript-eslint/parser',
// Specifies the ESLint parser
extends: [
'plugin:storybook/recommended',
'plugin:@typescript-eslint/recommended',
'plugin:jsx-a11y/recommended',
'plugin:react-hooks/recommended',
'plugin:react/recommended',
'plugin:react/jsx-runtime'
],
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
// Allows for the use of imports
ecmaFeatures: {
jsx: true // Allows for the parsing of JSX
}
},
ignorePatterns: ['!.storybook'], // do NOT ignore .storybook config files
// some personal preferences
rules: {
'comma-spacing': 'error',
'eqeqeq': ['error', 'always'],
'indent': ['error', 2],
'linebreak-style': 'error',
'no-tabs': 'error',
'object-curly-spacing': ['error', 'always'],
'one-var': ['error', 'never'],
'quotes': ['error', 'single'],
'semi': ['error', 'never'],
},
settings: {
react: {
version: 'detect'
},
jest: {
version: 'detect'
}
}
}