ci: update tsconfig and refactor eslintrc (#2069)

This commit is contained in:
Amir Zarrinkafsh 2021-06-08 10:14:51 +10:00 committed by GitHub
parent c555c10496
commit 0bc92404bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 25 additions and 39 deletions

View File

@ -1,49 +1,34 @@
module.exports = {
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": "tsconfig.json"
parser: "@typescript-eslint/parser",
parserOptions: {
project: "tsconfig.json",
},
"ignorePatterns": [
"build/*",
"coverage/*"
],
"settings": {
ignorePatterns: ["build/*", "coverage/*"],
settings: {
"import/resolver": {
"typescript": {}
}
typescript: {},
},
"extends": [
"react-app",
"plugin:import/errors",
"plugin:import/warnings",
"plugin:prettier/recommended",
"prettier"
],
"rules": {
},
extends: ["react-app", "plugin:import/errors", "plugin:import/warnings", "plugin:prettier/recommended", "prettier"],
rules: {
"import/order": [
"error",
{
"groups": [
"builtin",
"external",
"internal"
],
"pathGroups": [
groups: ["builtin", "external", "internal"],
pathGroups: [
{
"pattern": "react",
"group": "external",
"position": "before"
}
],
"pathGroupsExcludedImportTypes": [
"react"
pattern: "react",
group: "external",
position: "before",
},
],
pathGroupsExcludedImportTypes: ["react"],
"newlines-between": "always",
"alphabetize": {
"order": "asc",
"caseInsensitive": true
}
}
]
}
alphabetize: {
order: "asc",
caseInsensitive: true,
},
},
],
},
};

View File

@ -21,6 +21,7 @@
"noFallthroughCasesInSwitch": true
},
"include": [
".*.js",
"src",
"types"
]