Enforce some naming conventions (#4813)

Signed-off-by: DmitriyNoa <dmytro.zharkov@gmail.com>
This commit is contained in:
Sebastian Malton authored and DmitriyNoa committed 2022-03-03 14:40:53 +01:00
1 parent 752f1fd8af
commit c65a1f3f61
197 files changed
+630 -634

No files matched your search

+23
View File
@@ -146,6 +146,29 @@ module.exports = {
"named": "never",
"asyncArrow": "always",
}],
"@typescript-eslint/naming-convention": ["error",
{
"selector": "interface",
"format": ["PascalCase"],
"leadingUnderscore": "forbid",
"trailingUnderscore": "forbid",
"custom": {
"regex": "^Props$",
"match": false,
},
},
{
"selector": "typeAlias",
"format": ["PascalCase"],
"leadingUnderscore": "forbid",
"trailingUnderscore": "forbid",
"custom": {
"regex": "^(Props|State)$",
"match": false,
},
},
],
"@typescript-eslint/consistent-type-definitions": ["error", "interface"],
"unused-imports/no-unused-imports-ts": process.env.PROD === "true" ? "error" : "warn",
"unused-imports/no-unused-vars-ts": [
"warn", {