Skip to content

Commit

Permalink
Introduce a local eslint config.
Browse files Browse the repository at this point in the history
  • Loading branch information
iclanton committed Sep 26, 2023
1 parent 59d815d commit 0e54561
Show file tree
Hide file tree
Showing 192 changed files with 648 additions and 435 deletions.
7 changes: 2 additions & 5 deletions apps/api-documenter/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/api-documenter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"resolve": "~1.22.1"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"local-node-rig": "workspace:*",
"@types/js-yaml": "3.12.1",
Expand Down
7 changes: 2 additions & 5 deletions apps/api-extractor/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/api-extractor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"typescript": "~5.0.4"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "0.59.0",
"@rushstack/heft-node-rig": "2.2.23",
"@types/heft-jest": "1.0.1",
Expand Down
7 changes: 2 additions & 5 deletions apps/heft/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/heft/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
},
"devDependencies": {
"@microsoft/api-extractor": "workspace:*",
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "0.59.0",
"@rushstack/heft-node-rig": "2.2.23",
"@types/argparse": "1.0.38",
Expand Down
4 changes: 2 additions & 2 deletions apps/lockfile-explorer-web/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/web-app', '@rushstack/eslint-config/mixins/react'],
extends: ['eslint-config-local/profile/web-app', 'eslint-config-local/mixins/react'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/lockfile-explorer-web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"@rushstack/rush-themed-ui": "workspace:*"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"@types/react-dom": "16.9.14",
"@types/react": "16.14.23",
Expand Down
4 changes: 2 additions & 2 deletions apps/lockfile-explorer/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node'],
extends: ['eslint-config-local/profile/node'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/lockfile-explorer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
},
"devDependencies": {
"@microsoft/rush-lib": "workspace:*",
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"local-node-rig": "workspace:*",
"@rushstack/heft": "workspace:*",
"@rushstack/lockfile-explorer-web": "workspace:*",
Expand Down
7 changes: 2 additions & 5 deletions apps/rundown/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/rundown/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"string-argv": "~0.3.1"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"local-node-rig": "workspace:*"
}
Expand Down
7 changes: 2 additions & 5 deletions apps/rush/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/rush/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
"semver": "~7.5.4"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"local-node-rig": "workspace:*",
"@rushstack/rush-amazon-s3-build-cache-plugin": "workspace:*",
Expand Down
7 changes: 2 additions & 5 deletions apps/trace-import/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion apps/trace-import/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"typescript": "~5.0.4"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"local-node-rig": "workspace:*",
"@types/resolve": "1.20.2",
Expand Down
4 changes: 2 additions & 2 deletions build-tests-samples/heft-node-basic-tutorial/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node'],
extends: ['eslint-config-local/profile/node'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion build-tests-samples/heft-node-basic-tutorial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"_phase:test": "heft run --only test -- --clean"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"@rushstack/heft-jest-plugin": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
Expand Down
4 changes: 2 additions & 2 deletions build-tests-samples/heft-node-jest-tutorial/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node'],
extends: ['eslint-config-local/profile/node'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion build-tests-samples/heft-node-jest-tutorial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"_phase:test": "heft run --only test -- --clean"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"@rushstack/heft-jest-plugin": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
Expand Down
4 changes: 2 additions & 2 deletions build-tests-samples/heft-node-rig-tutorial/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node'],
extends: ['eslint-config-local/profile/node'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion build-tests-samples/heft-node-rig-tutorial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"_phase:test": "heft run --only test -- --clean"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"@rushstack/heft-node-rig": "workspace:*",
"@types/heft-jest": "1.0.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node'],
extends: ['eslint-config-local/profile/node'],
parserOptions: { tsconfigRootDir: __dirname }
};
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"_phase:test": "heft run --only test -- --clean"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft-jest-plugin": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
"@rushstack/heft-serverless-stack-plugin": "workspace:*",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/web-app', '@rushstack/eslint-config/mixins/react'],
extends: ['eslint-config-local/profile/web-app', 'eslint-config-local/mixins/react'],
parserOptions: { tsconfigRootDir: __dirname }
};
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"devDependencies": {
"@babel/core": "~7.20.0",
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft-jest-plugin": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
"@rushstack/heft-storybook-plugin": "workspace:*",
Expand Down
4 changes: 2 additions & 2 deletions build-tests-samples/heft-web-rig-app-tutorial/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/web-app', '@rushstack/eslint-config/mixins/react'],
extends: ['eslint-config-local/profile/web-app', 'eslint-config-local/mixins/react'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion build-tests-samples/heft-web-rig-app-tutorial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"tslib": "~2.3.1"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft-web-rig": "workspace:*",
"@rushstack/heft": "workspace:*",
"@types/react-dom": "16.9.14",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/web-app', '@rushstack/eslint-config/mixins/react'],
extends: ['eslint-config-local/profile/web-app', 'eslint-config-local/mixins/react'],
parserOptions: { tsconfigRootDir: __dirname }
};
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"tslib": "~2.3.1"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft-web-rig": "workspace:*",
"@rushstack/heft": "workspace:*",
"@types/react-dom": "16.9.14",
Expand Down
4 changes: 2 additions & 2 deletions build-tests-samples/heft-webpack-basic-tutorial/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/web-app', '@rushstack/eslint-config/mixins/react'],
extends: ['eslint-config-local/profile/web-app', 'eslint-config-local/mixins/react'],
parserOptions: { tsconfigRootDir: __dirname }
};
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"tslib": "~2.3.1"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft-jest-plugin": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
"@rushstack/heft-typescript-plugin": "workspace:*",
Expand Down
4 changes: 2 additions & 2 deletions build-tests-samples/packlets-tutorial/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: ['@rushstack/eslint-config/profile/node', '@rushstack/eslint-config/mixins/packlets'],
extends: ['eslint-config-local/profile/node', 'eslint-config-local/mixins/packlets'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion build-tests-samples/packlets-tutorial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"_phase:build": "heft run --only build -- --clean"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
"@rushstack/heft-typescript-plugin": "workspace:*",
Expand Down
9 changes: 3 additions & 6 deletions build-tests/eslint-7-test/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname },

overrides: [
/**
* Override the parser from @rushstack/eslint-config. Since the config is coming
* Override the parser from local-eslint-config. Since the config is coming
* from the workspace instead of the external NPM package, the versions of ESLint
* and TypeScript that the config consumes will be resolved from the devDependencies
* of the config instead of from the eslint-7-test package. Overriding the parser
Expand Down
2 changes: 1 addition & 1 deletion build-tests/eslint-7-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"_phase:build": "heft run --only build -- --clean"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"local-node-rig": "workspace:*",
"@types/node": "18.17.15",
Expand Down
7 changes: 2 additions & 5 deletions build-tests/heft-example-plugin-01/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution');
require('eslint-config-local/patch/modern-module-resolution');

module.exports = {
extends: [
'@rushstack/eslint-config/profile/node-trusted-tool',
'@rushstack/eslint-config/mixins/friendly-locals'
],
extends: ['eslint-config-local/profile/node-trusted-tool', 'eslint-config-local/mixins/friendly-locals'],
parserOptions: { tsconfigRootDir: __dirname }
};
2 changes: 1 addition & 1 deletion build-tests/heft-example-plugin-01/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"tapable": "1.1.3"
},
"devDependencies": {
"@rushstack/eslint-config": "workspace:*",
"eslint-config-local": "workspace:*",
"@rushstack/heft": "workspace:*",
"@rushstack/heft-lint-plugin": "workspace:*",
"@rushstack/heft-typescript-plugin": "workspace:*",
Expand Down
Loading

0 comments on commit 0e54561

Please sign in to comment.