From: Tim Düsterhus Date: Wed, 13 Sep 2023 07:39:52 +0000 (+0200) Subject: Update .eslintrc.js based on com.woltlab.wcf.conversation X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=473f0af83ed161229515f0e43c789be58f2b5b06;p=GitHub%2FWoltLab%2Fwoltlab.github.io.git Update .eslintrc.js based on com.woltlab.wcf.conversation --- diff --git a/snippets/typescript/.eslintrc.js b/snippets/typescript/.eslintrc.js index e7786437..99c4b8bd 100644 --- a/snippets/typescript/.eslintrc.js +++ b/snippets/typescript/.eslintrc.js @@ -1,37 +1,34 @@ module.exports = { - root: true, - parser: "@typescript-eslint/parser", - parserOptions: { - tsconfigRootDir: __dirname, - project: ["./tsconfig.json"] - }, - plugins: ["@typescript-eslint"], - extends: [ - "eslint:recommended", - "plugin:@typescript-eslint/recommended", - "plugin:@typescript-eslint/recommended-requiring-type-checking", - "prettier", - "prettier/@typescript-eslint" + root: true, + parser: "@typescript-eslint/parser", + parserOptions: { + tsconfigRootDir: __dirname, + project: ["./tsconfig.json"] + }, + plugins: ["@typescript-eslint"], + extends: [ + "eslint:recommended", + "plugin:@typescript-eslint/recommended", + "plugin:@typescript-eslint/recommended-type-checked", + "plugin:@typescript-eslint/strict", + "plugin:@typescript-eslint/strict-type-checked", + "plugin:@typescript-eslint/stylistic", + "plugin:@typescript-eslint/stylistic-type-checked", + "prettier" + ], + rules: { + "@typescript-eslint/no-non-null-assertion": 0, + "@typescript-eslint/consistent-type-definitions": 0, + "@typescript-eslint/prefer-nullish-coalescing": 0, + "@typescript-eslint/no-unused-vars": [ + "error", { + "argsIgnorePattern": "^_" + } ], - rules: { - "@typescript-eslint/ban-types": [ - "error", { - types: { - "object": false - }, - extendDefaults: true - } - ], - "@typescript-eslint/no-explicit-any": 0, - "@typescript-eslint/no-non-null-assertion": 0, - "@typescript-eslint/no-unsafe-assignment": 0, - "@typescript-eslint/no-unsafe-call": 0, - "@typescript-eslint/no-unsafe-member-access": 0, - "@typescript-eslint/no-unsafe-return": 0, - "@typescript-eslint/no-unused-vars": [ - "error", { - "argsIgnorePattern": "^_" - } - ] - } -}; \ No newline at end of file + "@typescript-eslint/strict-boolean-expressions": [ + "error", { + "allowNullableBoolean": true + } + ], + } +};