-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: convert workspace projects from TSLint to ESLint (#139)
- Loading branch information
1 parent
ff29288
commit 4cc50e7
Showing
50 changed files
with
1,776 additions
and
441 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,199 @@ | ||
{ | ||
"root": true, | ||
"ignorePatterns": ["**/*"], | ||
"plugins": ["@nrwl/nx"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"], | ||
"rules": { | ||
"@nrwl/nx/enforce-module-boundaries": [ | ||
"error", | ||
{ | ||
"allow": ["@nx-example/shared/product/data/testing"], | ||
"depConstraints": [ | ||
{ | ||
"sourceTag": "type:app", | ||
"onlyDependOnLibsWithTags": ["type:feature", "type:ui"] | ||
}, | ||
{ | ||
"sourceTag": "type:feature", | ||
"onlyDependOnLibsWithTags": [ | ||
"type:ui", | ||
"type:data", | ||
"type:types", | ||
"type:state" | ||
] | ||
}, | ||
{ | ||
"sourceTag": "type:types", | ||
"onlyDependOnLibsWithTags": ["type:types"] | ||
}, | ||
{ | ||
"sourceTag": "type:state", | ||
"onlyDependOnLibsWithTags": [ | ||
"type:state", | ||
"type:types", | ||
"type:data" | ||
] | ||
}, | ||
{ | ||
"sourceTag": "type:data", | ||
"onlyDependOnLibsWithTags": ["type:types"] | ||
}, | ||
{ | ||
"sourceTag": "type:e2e", | ||
"onlyDependOnLibsWithTags": ["type:e2e-utils"] | ||
}, | ||
{ | ||
"sourceTag": "type:ui", | ||
"onlyDependOnLibsWithTags": ["type:types", "type:ui"] | ||
}, | ||
{ | ||
"sourceTag": "scope:products", | ||
"onlyDependOnLibsWithTags": ["scope:products", "scope:shared"] | ||
}, | ||
{ | ||
"sourceTag": "scope:cart", | ||
"onlyDependOnLibsWithTags": ["scope:cart", "scope:shared"] | ||
} | ||
], | ||
"enforceBuildableLibDependency": true | ||
} | ||
] | ||
} | ||
}, | ||
{ | ||
"files": ["*.ts", "*.tsx"], | ||
"extends": ["plugin:@nrwl/nx/typescript"], | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.js", "*.jsx"], | ||
"extends": ["plugin:@nrwl/nx/javascript"], | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.ts"], | ||
"rules": { | ||
"@angular-eslint/component-selector": [ | ||
"error", | ||
{ | ||
"type": "element", | ||
"prefix": "app", | ||
"style": "kebab-case" | ||
} | ||
], | ||
"@angular-eslint/directive-selector": [ | ||
"error", | ||
{ | ||
"type": "attribute", | ||
"prefix": "app", | ||
"style": "camelCase" | ||
} | ||
], | ||
"@angular-eslint/no-conflicting-lifecycle": "error", | ||
"@angular-eslint/no-host-metadata-property": "error", | ||
"@angular-eslint/no-input-rename": "error", | ||
"@angular-eslint/no-inputs-metadata-property": "error", | ||
"@angular-eslint/no-output-native": "error", | ||
"@angular-eslint/no-output-on-prefix": "error", | ||
"@angular-eslint/no-output-rename": "error", | ||
"@angular-eslint/no-outputs-metadata-property": "error", | ||
"@angular-eslint/use-lifecycle-interface": "error", | ||
"@angular-eslint/use-pipe-transform-interface": "error", | ||
"@typescript-eslint/consistent-type-definitions": "error", | ||
"@typescript-eslint/no-explicit-any": "off", | ||
"@typescript-eslint/no-namespace": "off", | ||
"@typescript-eslint/dot-notation": "off", | ||
"@typescript-eslint/explicit-member-accessibility": [ | ||
"off", | ||
{ | ||
"accessibility": "explicit" | ||
} | ||
], | ||
"@typescript-eslint/member-ordering": "error", | ||
"@typescript-eslint/naming-convention": "warn", | ||
"@typescript-eslint/no-empty-function": "off", | ||
"@typescript-eslint/no-empty-interface": "error", | ||
"@typescript-eslint/no-inferrable-types": [ | ||
"error", | ||
{ | ||
"ignoreParameters": true | ||
} | ||
], | ||
"@typescript-eslint/no-misused-new": "error", | ||
"@typescript-eslint/no-non-null-assertion": "error", | ||
"@typescript-eslint/no-shadow": [ | ||
"error", | ||
{ | ||
"hoist": "all" | ||
} | ||
], | ||
"@typescript-eslint/no-unused-expressions": "error", | ||
"@typescript-eslint/prefer-function-type": "error", | ||
"@typescript-eslint/unified-signatures": "error", | ||
"arrow-body-style": "error", | ||
"constructor-super": "error", | ||
"eqeqeq": ["error", "smart"], | ||
"guard-for-in": "error", | ||
"id-blacklist": "off", | ||
"id-match": "off", | ||
"import/no-deprecated": "warn", | ||
"import/order": "error", | ||
"no-bitwise": "error", | ||
"no-caller": "error", | ||
"no-console": [ | ||
"error", | ||
{ | ||
"allow": [ | ||
"log", | ||
"warn", | ||
"dir", | ||
"timeLog", | ||
"assert", | ||
"clear", | ||
"count", | ||
"countReset", | ||
"group", | ||
"groupEnd", | ||
"table", | ||
"dirxml", | ||
"error", | ||
"groupCollapsed", | ||
"Console", | ||
"profile", | ||
"profileEnd", | ||
"timeStamp", | ||
"context" | ||
] | ||
} | ||
], | ||
"no-debugger": "error", | ||
"no-empty": "off", | ||
"no-eval": "error", | ||
"no-fallthrough": "error", | ||
"no-new-wrappers": "error", | ||
"no-restricted-imports": ["error", "rxjs/Rx"], | ||
"no-throw-literal": "error", | ||
"no-undef-init": "error", | ||
"no-underscore-dangle": "off", | ||
"no-var": "error", | ||
"prefer-const": "error", | ||
"radix": "error" | ||
}, | ||
"plugins": [ | ||
"eslint-plugin-import", | ||
"@angular-eslint/eslint-plugin", | ||
"@typescript-eslint" | ||
] | ||
}, | ||
{ | ||
"files": ["*.html"], | ||
"rules": { | ||
"@angular-eslint/template/banana-in-box": "error", | ||
"@angular-eslint/template/no-negated-async": "error" | ||
}, | ||
"plugins": ["@angular-eslint/eslint-plugin-template"] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"extends": ["plugin:cypress/recommended", "../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"], | ||
"parserOptions": { | ||
"project": "apps/cart-e2e/tsconfig.*?.json" | ||
}, | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["src/plugins/index.js"], | ||
"rules": { | ||
"@typescript-eslint/no-var-requires": "off", | ||
"no-undef": "off" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"extends": ["plugin:@nrwl/nx/react", "../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"], | ||
"parserOptions": { | ||
"project": ["apps/cart/tsconfig.*?.json"] | ||
}, | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.ts", "*.tsx"], | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.js", "*.jsx"], | ||
"rules": {} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"extends": ["plugin:cypress/recommended", "../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"], | ||
"parserOptions": { | ||
"project": "apps/products-e2e/tsconfig.*?.json" | ||
}, | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["src/plugins/index.js"], | ||
"rules": { | ||
"@typescript-eslint/no-var-requires": "off", | ||
"no-undef": "off" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
{ | ||
"extends": ["../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts"], | ||
"extends": [ | ||
"plugin:@nrwl/nx/angular", | ||
"plugin:@angular-eslint/template/process-inline-templates" | ||
], | ||
"parserOptions": { | ||
"project": ["apps/products/tsconfig.*?.json"] | ||
}, | ||
"rules": { | ||
"@angular-eslint/directive-selector": [ | ||
"error", | ||
{ | ||
"type": "attribute", | ||
"prefix": "nxExample", | ||
"style": "camelCase" | ||
} | ||
], | ||
"@angular-eslint/component-selector": [ | ||
"error", | ||
{ | ||
"type": "element", | ||
"prefix": "nx-example", | ||
"style": "kebab-case" | ||
} | ||
] | ||
}, | ||
"plugins": ["@angular-eslint/eslint-plugin", "@typescript-eslint"] | ||
}, | ||
{ | ||
"files": ["*.html"], | ||
"extends": ["plugin:@nrwl/nx/angular-template"], | ||
"rules": {} | ||
} | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.