generated from nju33/gitpod-workspace
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
44 lines (43 loc) · 1.25 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
const rulesDirPlugin = require('eslint-plugin-rulesdir')
rulesDirPlugin.RULES_DIR = './src/rules'
/**
* @type {import('eslint').Linter.Config}
*/
module.exports = {
plugins: ['simple-import-sort', 'tsdoc', 'react-hooks', 'rulesdir'],
rules: {
'sort-imports': 'off',
'import/order': 'off',
'simple-import-sort/imports': [
'error',
{ groups: [['^\\u0000', '^@?\\w', '^[^.]', '^\\.']] }
]
},
parser: '@typescript-eslint/parser',
parserOptions: { project: './tsconfig.json' },
extends: ['standard-with-typescript', 'standard-react', 'prettier'],
overrides: [
{ files: ['*.ts', '*.tsx'], rules: { 'tsdoc/syntax': 'warn' } },
{
files: ['*.js', '*.jsx', '*.ts', '*.tsx'],
rules: { 'react/prop-types': 'off' }
},
{
files: ['src/fixtures/**/*.ts', 'src/fixtures/**/*.tsx'],
rules: {
'@typescript-eslint/no-unused-vars': 'off',
'react/react-in-jsx-scope': 'off',
'rulesdir/restrict': [
process.env.CI === 'true' ? 'off' : 'error',
{ whiteList: ['w-\\[@(762|766)px\\]', 'h-*'] }
]
}
}
],
env: { jest: true, browser: true, node: true },
settings: {
'tailwindcss-jit-restrict': {
whiteList: ['w-\\[@(762|766)px\\]', 'h-*']
}
}
}