Skip to content

Commit

Permalink
chore: fix ESLint not finding the tsconfig.json files (#811)
Browse files Browse the repository at this point in the history
  • Loading branch information
bapmrl authored Jan 18, 2023
1 parent ab82d15 commit 8b21073
Show file tree
Hide file tree
Showing 14 changed files with 120 additions and 94 deletions.
3 changes: 3 additions & 0 deletions e2e-projects/next/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module.exports = {
extends: ["next/babel", "next/core-web-vitals"]
}
3 changes: 0 additions & 3 deletions e2e-projects/next/.eslintrc.json

This file was deleted.

28 changes: 28 additions & 0 deletions packages/client/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
module.exports = {
settings: {
"import/resolver": {
typescript: {},
},
},
parser: "@typescript-eslint/parser",
parserOptions: {
project: [
"../../tsconfig-node.json",
"./__tests__/tsconfig.json",
"./tsconfig.json",
],
tsconfigRootDir: __dirname,
},
plugins: ["@typescript-eslint", "import", "jest"],
extends: [
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"plugin:jest/recommended",
"eslint-config-prettier",
],
ignorePatterns: ["build"],
rules: {
"jest/no-mocks-import": "off",
"jest/no-conditional-expect": "off",
},
};
25 changes: 0 additions & 25 deletions packages/client/.eslintrc.json

This file was deleted.

8 changes: 8 additions & 0 deletions packages/client/__tests__/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"extends": "../tsconfig.json",
"compilerOptions": {
"noEmit": true,
"rootDir": ".."
},
"exclude": []
}
24 changes: 24 additions & 0 deletions packages/core/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
module.exports = {
settings: {
"import/resolver": {
typescript: {},
},
},
parser: "@typescript-eslint/parser",
parserOptions: {
project: [
"../../tsconfig-node.json",
"./__tests__/tsconfig.json",
"./tsconfig.json",
],
tsconfigRootDir: __dirname,
},
plugins: ["@typescript-eslint", "import", "jest"],
extends: [
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"plugin:jest/recommended",
"eslint-config-prettier",
],
ignorePatterns: ["build"],
};
21 changes: 0 additions & 21 deletions packages/core/.eslintrc.json

This file was deleted.

4 changes: 2 additions & 2 deletions packages/core/__tests__/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"extends": "../tsconfig.json",
"compilerOptions": {
"noEmit": true
"noEmit": true,
"rootDir": ".."
},
"references": [{ "path": ".." }],
"exclude": []
}
24 changes: 24 additions & 0 deletions packages/init/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
module.exports = {
settings: {
"import/resolver": {
typescript: {},
},
},
parser: "@typescript-eslint/parser",
parserOptions: {
project: [
"../../tsconfig-node.json",
"./__tests__/tsconfig.json",
"./tsconfig.json",
],
tsconfigRootDir: __dirname,
},
plugins: ["@typescript-eslint", "import", "jest"],
extends: [
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"plugin:jest/recommended",
"eslint-config-prettier",
],
ignorePatterns: ["build"],
};
21 changes: 0 additions & 21 deletions packages/init/.eslintrc.json

This file was deleted.

2 changes: 1 addition & 1 deletion packages/init/__tests__/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
"compilerOptions": {
"noEmit": true
},
"references": [{ "path": ".." }]
"exclude": []
}
26 changes: 26 additions & 0 deletions packages/slice-machine/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
module.exports = {
settings: {
"import/resolver": {
typescript: {},
},
},
parser: "@typescript-eslint/parser",
parserOptions: {
project: [
"../../tsconfig-node.json",
"./scripts/tsconfig.json",
"./server/tsconfig.json",
"./tsconfig.json",
],
tsconfigRootDir: __dirname,
},
plugins: ["@typescript-eslint", "import", "jest"],
extends: [
"plugin:react-hooks/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"plugin:jest/recommended",
"eslint-config-prettier",
],
ignorePatterns: ["build", "templates", "**/tests/**", "helpers/**"],
};
21 changes: 0 additions & 21 deletions packages/slice-machine/.eslintrc.json

This file was deleted.

4 changes: 4 additions & 0 deletions tsconfig-node.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"compilerOptions": { "noEmit": true },
"include": ["packages/*/.eslintrc.js"]
}

0 comments on commit 8b21073

Please sign in to comment.