Skip to content

Commit c0db6d8

Browse files
style: update linting
1 parent 5c6b1a2 commit c0db6d8

File tree

6 files changed

+19
-19
lines changed

6 files changed

+19
-19
lines changed

.eslintrc.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -129,23 +129,23 @@
129129
"import/no-unresolved": "off",
130130
"init-declarations": "off",
131131
"jsdoc/require-jsdoc": "off",
132-
"no-console": "off",
133-
"no-empty": "off",
134-
"no-invalid-this": "off",
135-
"no-undef": "off",
136-
"no-useless-return": "off",
137-
"node/handle-callback-err": "off",
132+
"n/handle-callback-err": "off",
138133
"prefer-const": "off",
139134
"prettier/prettier": "off",
140135
"sonarjs/no-extra-arguments": "off",
141136
"sonarjs/no-unused-collection": "off",
142137
"unicorn/prefer-optional-catch-binding": "off",
143138
"unicorn/prefer-top-level-await": "off",
144139
"unicorn/switch-case-braces": "off",
145-
146-
"dot-notation": "error",
147-
"no-implied-eval": "error",
148-
"require-await": "error"
140+
"no-console": "off",
141+
"no-empty": "off",
142+
"no-invalid-this": "off",
143+
"no-undef": "off",
144+
"no-useless-return": "off",
145+
"dot-notation": "off",
146+
"no-empty-function": "off",
147+
"no-throw-literal": "off",
148+
"no-unused-vars": "off"
149149
}
150150
}
151151
]

docs/rules/prefer-immutable-types.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ interface Foo1 {
6161
interface Foo2 {
6262
new (arg: string[]): void;
6363
}
64-
const x = { foo(arg: string[]): void; };
64+
const x = { foo(arg: string[]): void {} };
6565
function foo(arg: string[]);
6666
type Foo3 = (arg: string[]) => void;
6767
interface Foo4 {
@@ -113,11 +113,14 @@ function primitive9(arg: string | number | undefined) {}
113113

114114
function fnSig(arg: () => void) {}
115115

116-
enum Foo { a, b }
116+
enum Foo {
117+
a,
118+
b,
119+
}
117120
function enum1(arg: Foo) {}
118121

119122
function symb1(arg: symbol) {}
120-
const customSymbol = Symbol('a');
123+
const customSymbol = Symbol("a");
121124
function symb2(arg: typeof customSymbol) {}
122125

123126
// function types
@@ -127,7 +130,7 @@ interface Foo1 {
127130
interface Foo2 {
128131
new (arg: ReadonlyArray<string>): void;
129132
}
130-
const x = { foo(arg: ReadonlyArray<string>): void; };
133+
const x = { foo(arg: ReadonlyArray<string>): void {} };
131134
function foo(arg: ReadonlyArray<string>);
132135
type Foo3 = (arg: ReadonlyArray<string>) => void;
133136
interface Foo4 {

docs/rules/prefer-readonly-type.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ Examples of **correct** code for the `{ "ignoreClass": true }` option:
157157
```ts
158158
/* eslint functional/prefer-readonly-type: ["error", { "ignoreClass": true }] */
159159

160-
class {
160+
class C {
161161
myprop: string;
162162
}
163163
```

scripts/.eslintrc.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
{
22
"rules": {
3-
"functional/no-return-void": "off",
4-
"node/no-unsupported-features/node-builtins": "off"
3+
"functional/no-return-void": "off"
54
}
65
}

src/rules/prefer-immutable-types.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import type { TSESLint, TSESTree } from "@typescript-eslint/utils";
22
import { deepmerge } from "deepmerge-ts";
33
import { Immutability } from "is-immutable-type";
44
import type { JSONSchema4 } from "json-schema";
5-
import { OptionalChain } from "typescript";
65

76
import type { IgnoreClassesOption } from "~/options";
87
import {

tests/helpers/configs.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import type { Linter } from "@typescript-eslint/utils/ts-eslint";
44

55
export const filename = path.join(__dirname, "file.ts");
66

7-
// eslint-disable-next-line node/no-missing-require -- See https://github.com/mysticatea/eslint-plugin-node/issues/255
87
const typescriptParser = require.resolve("@typescript-eslint/parser");
98
const babelParser = require.resolve("@babel/eslint-parser");
109
const espreeParser = require.resolve("espree");

0 commit comments

Comments
 (0)