Last active
April 7, 2021 21:20
-
-
Save brunolm/34f7ecbe6116d284d6e48617ff83371a to your computer and use it in GitHub Desktop.
.eslintrc (PascalCase for react)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"root": true, | |
"parser": "@typescript-eslint/parser", | |
"plugins": ["@typescript-eslint"], | |
"extends": [ | |
"eslint:recommended", | |
"plugin:@typescript-eslint/eslint-recommended", | |
"plugin:@typescript-eslint/recommended" | |
], | |
"rules": { | |
"@typescript-eslint/no-explicit-any": "off", | |
"@typescript-eslint/explicit-module-boundary-types": "off", | |
"@typescript-eslint/no-unused-vars": ["error", { "varsIgnorePattern": "^_" }], | |
"curly": ["error", "all"], | |
"complexity": ["error", { "max": 10 }], | |
"no-cond-assign": ["error", "except-parens"], | |
"newline-before-return": "error", | |
"no-bitwise": "off", | |
"prefer-object-spread": "error", | |
"prefer-template": "error", | |
"no-return-await": "error", | |
"no-else-return": "error", | |
"@typescript-eslint/naming-convention": [ | |
"error", | |
{ | |
"selector": "interface", | |
"format": ["PascalCase"], | |
"custom": { | |
"regex": "^I[A-Z]", | |
"match": false | |
} | |
}, | |
{ | |
"selector": "default", | |
"format": ["camelCase"], | |
"leadingUnderscore": "allow", | |
"trailingUnderscore": "allow" | |
}, | |
{ | |
"selector": "variable", | |
"format": ["camelCase", "PascalCase"], | |
"leadingUnderscore": "allow", | |
"trailingUnderscore": "allow" | |
}, | |
{ | |
"selector": "typeLike", | |
"format": ["PascalCase"] | |
} | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment