Skip to content

Commit

Permalink
remove unneeded rules, add config for scripts (#253)
Browse files Browse the repository at this point in the history
Signed-off-by: Kangrui Johann Ye <[email protected]>
  • Loading branch information
strawberry-choco authored Nov 15, 2024
1 parent ebc7e06 commit bc2469b
Show file tree
Hide file tree
Showing 33 changed files with 66 additions and 1,061 deletions.
11 changes: 1 addition & 10 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,14 @@ export default tseslint.config(
includeIgnoreFile(gitignorePath),
...cloudflightTypescriptConfig({
rootDirectory: import.meta.dirname,
tsConfigFiles: ['./packages/*/tsconfig.json', './packages/*/tsconfig.spec.json'],
tsConfigFiles: ['./packages/*/tsconfig.json', './packages/*/tsconfig.spec.json', './tsconfig.eslint.json'],
}),
{
// these files are temporarily disabled for linting
// until we are done with migrating everything to v9
ignores: [
'packages/eslint-plugin-angular/src/configs/format-template.ts',
'packages/eslint-plugin-typescript/src/configs/index.ts',
'packages/eslint-plugin-typescript/src/configs/json.ts',
'packages/eslint-plugin-typescript/src/configs/package.ts',
'packages/eslint-plugin-typescript/src/rules/package/*',
'packages/eslint-plugin-typescript/src/rules/ts-config/*',
'packages/eslint-plugin-typescript/src/rules/typescript/*.spec.ts',
'scripts/*',
'eslint.config.mjs',
'eslint.format.mjs',
'jest.config*.ts',
],
},
{
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"lint": "eslint . && eslint -c eslint.format.mjs .",
"test": "yarn workspaces foreach -pA run test-package",
"postinstall": "husky",
"publish-workspaces": "node ./scripts/prepare.js && yarn workspaces foreach -A --no-private npm publish"
"publish-workspaces": "node ./scripts/prepare.mjs && yarn workspaces foreach -A --no-private npm publish"
},
"keywords": [
"eslint",
Expand Down
39 changes: 0 additions & 39 deletions packages/eslint-plugin-typescript/src/configs/json.ts

This file was deleted.

13 changes: 0 additions & 13 deletions packages/eslint-plugin-typescript/src/configs/package.ts

This file was deleted.

18 changes: 0 additions & 18 deletions packages/eslint-plugin-typescript/src/rules/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,6 @@ import {NoMomentJsRule, NoMomentJsRuleName} from './typescript/no-moment-js';
import {NoOnEventAssign, NoOnEventAssignName} from './typescript/no-on-event-assign';

const rules: Record<string, TSESLint.RuleModule<string, readonly unknown[]>> = {
// todo: eslint-plugin-json-es is not compatible with eslint v9 as of writing
// and will be migrated later
// [PackageForcePrivateRuleName]: PackageForcePrivateRule,
// [PackageForceAbsoluteVersionDependenciesRuleName]: PackageForceAbsoluteVersionDependenciesRule,
// [TscAllowUnreachableCodeRuleName]: TscAllowUnreachableCodeRule,
// [TscAllowUnusedLabelsRuleName]: TscAllowUnusedLabelsRule,
// [TscEsModuleInteropRuleName]: TscEsModuleInteropRule,
// [TscForceConsistentCasingInFileNamesRuleName]: TscForceConsistentCasingInFileNamesRule,
// [TscImportHelpersRuleName]: TscImportHelpersRule,
// [TscImportsNotUsedAsValuesRuleName]: TscImportsNotUsedAsValuesRule,
// [TscIsolatedModulesRuleName]: TscIsolatedModulesRule,
// [TscNoFallThroughCasesInSwitchRuleName]: TscNoFallThroughCasesInSwitchRule,
// [TscNoImplicitOverrideRuleName]: TscNoImplicitOverrideRule,
// [TscNoImplicitReturnsRuleName]: TscNoImplicitReturnsRule,
// [TscNoPropertyAccessFromIndexSignatureRuleName]: TscNoPropertyAccessFromIndexSignatureRule,
// [TscNoUncheckedIndexedAccessRuleName]: TscNoUncheckedIndexedAccessRule,
// [TscStrictRuleName]: TscStrictRule,
// [TscUseDefineForClassFieldsRuleName]: TscUseDefineForClassFieldsRule,
[NoMomentJsRuleName]: NoMomentJsRule,
[NoOnEventAssignName]: NoOnEventAssign,
};
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit bc2469b

Please sign in to comment.