Skip to content

Commit

Permalink
add more projects
Browse files Browse the repository at this point in the history
  • Loading branch information
Cammisuli committed Nov 4, 2024
1 parent 36f9ac1 commit 97e5d67
Show file tree
Hide file tree
Showing 64 changed files with 2,155 additions and 7 deletions.
6 changes: 5 additions & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"recommendations": ["nrwl.angular-console", "esbenp.prettier-vscode"]
"recommendations": [
"nrwl.angular-console",
"esbenp.prettier-vscode",
"firsttris.vscode-jest-runner"
]
}
33 changes: 33 additions & 0 deletions eslint.base.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
const nx = require('@nx/eslint-plugin');

module.exports = [
...nx.configs['flat/base'],
...nx.configs['flat/typescript'],
...nx.configs['flat/javascript'],
{
ignores: ['**/dist'],
},
{
files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'],
rules: {
'@nx/enforce-module-boundaries': [
'error',
{
enforceBuildableLibDependency: true,
allow: ['^.*/eslint(\\.base)?\\.config\\.[cm]?js$'],
depConstraints: [
{
sourceTag: '*',
onlyDependOnLibsWithTags: ['*'],
},
],
},
],
},
},
{
files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'],
// Override or add rules here
rules: {},
},
];
5 changes: 2 additions & 3 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
const baseConfig = require('./eslint.base.config.js');
const nx = require('@nx/eslint-plugin');

module.exports = [
...nx.configs['flat/base'],
...nx.configs['flat/typescript'],
...nx.configs['flat/javascript'],
...baseConfig,
{
ignores: ['**/dist'],
},
Expand Down
5 changes: 5 additions & 0 deletions jest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { getJestProjectsAsync } from '@nx/jest';

export default async () => ({
projects: await getJestProjectsAsync(),
});
3 changes: 3 additions & 0 deletions jest.preset.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
const nxPreset = require('@nx/jest/preset').default;

module.exports = { ...nxPreset };
18 changes: 17 additions & 1 deletion nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
"!{projectRoot}/**/?(*.)+(spec|test).[jt]s?(x)?(.snap)",
"!{projectRoot}/tsconfig.spec.json",
"!{projectRoot}/.eslintrc.json",
"!{projectRoot}/eslint.config.js"
"!{projectRoot}/eslint.config.js",
"!{projectRoot}/jest.config.[jt]s",
"!{projectRoot}/src/test-setup.[jt]s",
"!{projectRoot}/test-setup.[jt]s"
],
"sharedGlobals": ["{workspaceRoot}/.github/workflows/ci.yml"]
},
Expand All @@ -28,6 +31,12 @@
"options": {
"targetName": "lint"
}
},
{
"plugin": "@nx/jest/plugin",
"options": {
"targetName": "test"
}
}
],
"defaultProject": "gcs-test",
Expand All @@ -50,5 +59,12 @@
},
"gcs": {
"bucket": "local-dev-cache-bucket-dvnfkf"
},
"targetDefaults": {
"@nx/js:tsc": {
"cache": true,
"dependsOn": ["^build"],
"inputs": ["production", "^production"]
}
}
}
6 changes: 6 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"@eslint/js": "^9.8.0",
"@nx/eslint": "20.0.8",
"@nx/eslint-plugin": "20.0.8",
"@nx/jest": "20.0.8",
"@nx/js": "20.0.8",
"@nx/powerpack-gcs-cache": "1.0.10-alpha.0",
"@nx/react": "20.0.8",
Expand All @@ -27,6 +28,7 @@
"@swc/core": "~1.5.7",
"@swc/helpers": "~0.5.11",
"@testing-library/react": "15.0.6",
"@types/jest": "^29.5.12",
"@types/node": "18.16.9",
"@types/react": "18.3.1",
"@types/react-dom": "18.3.0",
Expand All @@ -39,9 +41,13 @@
"eslint-plugin-jsx-a11y": "6.7.1",
"eslint-plugin-react": "7.35.0",
"eslint-plugin-react-hooks": "4.6.0",
"jest": "^29.7.0",
"jest-environment-node": "^29.7.0",
"jsdom": "~22.1.0",
"nx": "20.0.8",
"prettier": "^2.6.2",
"ts-jest": "^29.1.0",
"ts-node": "10.9.1",
"tslib": "^2.3.0",
"typescript": "~5.5.2",
"typescript-eslint": "^8.0.0",
Expand Down
Loading

0 comments on commit 97e5d67

Please sign in to comment.