From 077347f15fd6b36786f7a9a29669ad0e79b849ca Mon Sep 17 00:00:00 2001 From: jimmy-guzman Date: Sat, 13 Apr 2024 08:31:41 -0500 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20prevent=20redundant=20ren?= =?UTF-8?q?aming=20by=20adding=20`no-useless-rename`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/__snapshots__/factory.spec.ts.snap | 1 + src/__snapshots__/index.spec.ts.snap | 1 + src/rules/__snapshots__/base.spec.ts.snap | 1 + src/rules/base.ts | 1 + 4 files changed, 4 insertions(+) diff --git a/src/__snapshots__/factory.spec.ts.snap b/src/__snapshots__/factory.spec.ts.snap index 50e8797..f851747 100644 --- a/src/__snapshots__/factory.spec.ts.snap +++ b/src/__snapshots__/factory.spec.ts.snap @@ -72,6 +72,7 @@ exports[`jimmyDotCodes > should create default configuration 1`] = ` "no-useless-backreference": "error", "no-useless-catch": "error", "no-useless-escape": "error", + "no-useless-rename": "error", "no-with": "error", "object-shorthand": "error", "prefer-arrow-callback": "error", diff --git a/src/__snapshots__/index.spec.ts.snap b/src/__snapshots__/index.spec.ts.snap index f0e7906..79bc59e 100644 --- a/src/__snapshots__/index.spec.ts.snap +++ b/src/__snapshots__/index.spec.ts.snap @@ -72,6 +72,7 @@ exports[`should create default configuration 1`] = ` "no-useless-backreference": "error", "no-useless-catch": "error", "no-useless-escape": "error", + "no-useless-rename": "error", "no-with": "error", "object-shorthand": "error", "prefer-arrow-callback": "error", diff --git a/src/rules/__snapshots__/base.spec.ts.snap b/src/rules/__snapshots__/base.spec.ts.snap index 0073af2..76a7588 100644 --- a/src/rules/__snapshots__/base.spec.ts.snap +++ b/src/rules/__snapshots__/base.spec.ts.snap @@ -69,6 +69,7 @@ exports[`should create base rules 1`] = ` "no-useless-backreference": "error", "no-useless-catch": "error", "no-useless-escape": "error", + "no-useless-rename": "error", "no-with": "error", "object-shorthand": "error", "prefer-arrow-callback": "error", diff --git a/src/rules/base.ts b/src/rules/base.ts index 3401bdc..151b449 100644 --- a/src/rules/base.ts +++ b/src/rules/base.ts @@ -7,6 +7,7 @@ export const baseRules = { "curly": ["error", "multi-or-nest", "consistent"], "arrow-body-style": ["error", "always"], "object-shorthand": "error", + "no-useless-rename": "error", "prefer-arrow-callback": "error", "no-console": "warn", } satisfies Rules;