-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
71 lines (71 loc) · 1.84 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
module.exports = {
env: {
browser: true,
es2020: true,
node: true,
},
extends: [
'airbnb-base',
'airbnb-typescript/base',
'plugin:import/recommended',
'plugin:import/typescript',
'plugin:solid/typescript',
'plugin:prettier/recommended',
'plugin:jsx-a11y/recommended',
'plugin:tailwindcss/recommended',
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/recommended-requiring-type-checking',
'prettier',
],
parser: '@typescript-eslint/parser',
parserOptions: {
project: './tsconfig.json',
ecmaFeatures: { jsx: true },
ecmaVersion: 2021,
},
plugins: ['import', 'solid', 'jsx-a11y', 'prettier', '@typescript-eslint', 'tailwindcss'],
rules: {
'import/extensions': ['error', 'ignorePackages', { ts: 'never', tsx: 'never' }],
'prettier/prettier': 'error',
},
settings: {
linkComponents: ['Link'],
'import/parsers': {
'@typescript-eslint/parser': ['.ts', '.tsx'],
},
'import/resolver': {
typescript: {
extensions: ['.ts', '.tsx'],
},
},
'import/order': [
'warn',
{
groups: ['builtin', 'external', 'internal', 'parent', 'sibling', 'index', 'object', 'type'],
'newlines-between': 'always',
pathGroupsExcludedImportTypes: ['builtin'],
alphabetize: { order: 'asc', caseInsensitive: true },
pathGroups: [
{ pattern: 'src/types/**', group: 'internal', position: 'before' },
{
pattern: 'src/repositories/**',
group: 'internal',
position: 'before',
},
],
},
],
tailwindcss: {
whitelist: ['form-input'],
},
},
overrides: [
{
files: ['*.test.ts'],
rules: {
// See https://mochajs.org/#arrow-functions
'func-names': 'off',
},
},
],
};