mirror of https://github.com/stashapp/stash.git
80 lines
1.8 KiB
JSON
80 lines
1.8 KiB
JSON
{
|
|
"env": {
|
|
"browser": true
|
|
},
|
|
"parser": "@typescript-eslint/parser",
|
|
"parserOptions": {
|
|
"project": "./tsconfig.json"
|
|
},
|
|
"plugins": ["@typescript-eslint", "jsx-a11y"],
|
|
"extends": [
|
|
"airbnb-typescript",
|
|
"plugin:import/recommended",
|
|
"plugin:react/recommended",
|
|
"plugin:react/jsx-runtime",
|
|
"airbnb/hooks",
|
|
"prettier"
|
|
],
|
|
"settings": {
|
|
"react": {
|
|
"version": "detect"
|
|
}
|
|
},
|
|
"ignorePatterns": [
|
|
"node_modules/",
|
|
"src/core/generated-graphql.ts",
|
|
"src/pluginApi.d.ts"
|
|
],
|
|
"rules": {
|
|
"@typescript-eslint/lines-between-class-members": "off",
|
|
"@typescript-eslint/naming-convention": [
|
|
"error",
|
|
{
|
|
"selector": "interface",
|
|
"format": ["PascalCase"],
|
|
"custom": {
|
|
"regex": "^I[A-Z]",
|
|
"match": true
|
|
}
|
|
}
|
|
],
|
|
"@typescript-eslint/no-explicit-any": 2,
|
|
"@typescript-eslint/no-use-before-define": [
|
|
"error",
|
|
{ "functions": false, "classes": false }
|
|
],
|
|
"import/extensions": [
|
|
"error",
|
|
"ignorePackages",
|
|
{
|
|
"js": "never",
|
|
"jsx": "never",
|
|
"ts": "never",
|
|
"tsx": "never"
|
|
}
|
|
],
|
|
"import/named": "off",
|
|
"import/namespace": "off",
|
|
"import/no-unresolved": "off",
|
|
"lines-between-class-members": "off",
|
|
"no-nested-ternary": "off",
|
|
"prefer-destructuring": [
|
|
"error",
|
|
{
|
|
"VariableDeclarator": {
|
|
"array": false,
|
|
"object": true
|
|
},
|
|
"AssignmentExpression": {
|
|
"array": false,
|
|
"object": false
|
|
}
|
|
}
|
|
],
|
|
"react/display-name": "off",
|
|
"react/prop-types": "off",
|
|
"react/style-prop-object": ["error", { "allow": ["FormattedNumber"] }],
|
|
"spaced-comment": ["error", "always", { "markers": ["/"] }]
|
|
}
|
|
}
|