typecccccccccccc
Version:
p align="center" > <img src="https://xord.notion.site/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F283b98b7-fdae-4e5a-acaf-248242084e4a%2FICON.png?table=block&id=5306223c-a4f7-45d1-9f54-b9a5f4004cd6&spaceId=49976899-64a1-40f
193 lines (192 loc) • 5.24 kB
JavaScript
/* eslint-disable @typescript-eslint/naming-convention */
module.exports = {
env: {
browser: false,
es6: true,
node: true,
},
extends: ["plugin:prettier/recommended"],
parser: "@typescript-eslint/parser",
plugins: ["eslint-plugin-import", "@typescript-eslint"],
rules: {
"@typescript-eslint/adjacent-overload-signatures": "error",
"@typescript-eslint/array-type": [
"error",
{
default: "array-simple",
},
],
"@typescript-eslint/ban-types": [
"error",
{
types: {
Object: {
message: "Avoid using the `Object` type. Did you mean `object`?",
},
Boolean: {
message: "Avoid using the `Boolean` type. Did you mean `boolean`?",
},
Function: {
message:
"Avoid using the `Function` type. Prefer a specific function type, like `() => void`.",
},
Number: {
message: "Avoid using the `Number` type. Did you mean `number`?",
},
String: {
message: "Avoid using the `String` type. Did you mean `string`?",
},
Symbol: {
message: "Avoid using the `Symbol` type. Did you mean `symbol`?",
},
},
extendDefaults: false,
},
],
"@typescript-eslint/consistent-type-assertions": "error",
"@typescript-eslint/consistent-type-definitions": "error",
"@typescript-eslint/explicit-member-accessibility": [
"error",
{
accessibility: "explicit",
overrides: {
constructors: "no-public",
},
},
],
"@typescript-eslint/naming-convention": [
"error",
{
selector: "default",
format: ["camelCase"],
leadingUnderscore: "allow",
trailingUnderscore: "allow",
},
{
selector: ["variable", "parameter"],
format: ["camelCase", "UPPER_CASE", "PascalCase"],
leadingUnderscore: "allow",
trailingUnderscore: "allow",
},
{
selector: "classProperty",
format: ["camelCase", "UPPER_CASE"],
leadingUnderscore: "allow",
},
{
selector: "enumMember",
format: ["UPPER_CASE"],
},
{
selector: "memberLike",
modifiers: ["private"],
format: ["camelCase"],
leadingUnderscore: "require",
},
{
selector: ["objectLiteralProperty", "objectLiteralMethod"],
format: ["camelCase", "PascalCase", "snake_case", "UPPER_CASE"],
leadingUnderscore: "allow",
},
{
selector: "typeProperty",
format: ["camelCase", "PascalCase"],
leadingUnderscore: "allow",
},
{
selector: "typeLike",
format: ["PascalCase"],
},
],
"@typescript-eslint/no-empty-interface": "error",
"@typescript-eslint/no-misused-new": "error",
"@typescript-eslint/no-namespace": "error",
"@typescript-eslint/no-redeclare": "error",
"@typescript-eslint/no-shadow": [
"error",
{
hoist: "all",
},
],
"@typescript-eslint/no-this-alias": "error",
"@typescript-eslint/no-unused-expressions": "error",
"@typescript-eslint/no-unused-vars": [
"error",
{
argsIgnorePattern: "^_",
varsIgnorePattern: "^_",
},
],
"@typescript-eslint/prefer-for-of": "error",
"@typescript-eslint/prefer-function-type": "error",
"@typescript-eslint/prefer-namespace-keyword": "error",
"@typescript-eslint/triple-slash-reference": [
"error",
{
path: "always",
types: "prefer-import",
lib: "always",
},
],
"@typescript-eslint/unified-signatures": "error",
"constructor-super": "error",
eqeqeq: ["error", "always"],
"guard-for-in": "error",
"id-blacklist": "error",
"id-match": "error",
"import/no-extraneous-dependencies": [
"error",
{
devDependencies: false,
},
],
"import/order": [
"error",
{
groups: [
"type",
"object",
["builtin", "external"],
"parent",
"sibling",
"index",
],
},
],
"import/no-default-export": "error",
"no-bitwise": "error",
"no-caller": "error",
"no-cond-assign": "error",
"no-debugger": "error",
"no-duplicate-case": "error",
"no-duplicate-imports": "error",
"no-eval": "error",
"no-extra-bind": "error",
"no-new-func": "error",
"no-new-wrappers": "error",
"no-return-await": "off",
"no-sequences": "error",
"no-sparse-arrays": "error",
"no-template-curly-in-string": "error",
"no-throw-literal": "error",
"no-undef-init": "error",
"no-unsafe-finally": "error",
"no-unused-labels": "error",
"no-unused-vars": "off",
"no-var": "error",
"object-shorthand": "error",
"one-var": ["error", "never"],
"prefer-const": "error",
"prefer-object-spread": "error",
"prefer-template": "error",
radix: "error",
"spaced-comment": [
"error",
"always",
{
markers: ["/"],
},
],
"use-isnan": "error",
},
};