add web
This commit is contained in:
43
web/.eslintrc.js
Normal file
43
web/.eslintrc.js
Normal file
@@ -0,0 +1,43 @@
|
||||
// .eslintrc.js
|
||||
module.exports = {
|
||||
extends: [require.resolve('umi/eslint'), 'plugin:react-hooks/recommended'],
|
||||
plugins: ['check-file'],
|
||||
rules: {
|
||||
'@typescript-eslint/no-use-before-define': [
|
||||
'warn',
|
||||
{
|
||||
functions: false,
|
||||
variables: true,
|
||||
},
|
||||
],
|
||||
'check-file/filename-naming-convention': [
|
||||
'error',
|
||||
{
|
||||
'**/*.{jsx,tsx}': '[a-z0-9.-]*',
|
||||
'**/*.{js,ts}': '[a-z0-9.-]*',
|
||||
},
|
||||
],
|
||||
'check-file/folder-naming-convention': [
|
||||
'error',
|
||||
{
|
||||
'src/**/': 'KEBAB_CASE',
|
||||
'mocks/*/': 'KEBAB_CASE',
|
||||
},
|
||||
],
|
||||
'react/no-unescaped-entities': [
|
||||
'warn',
|
||||
{
|
||||
forbid: [
|
||||
{
|
||||
char: "'",
|
||||
alternatives: [''', '''],
|
||||
},
|
||||
{
|
||||
char: '"',
|
||||
alternatives: ['"', '"'],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user