Skip to content

Commit

Permalink
feat(repo): update to nx 10.3 (nrwl#3840)
Browse files Browse the repository at this point in the history
  • Loading branch information
FrozenPandaz authored Oct 2, 2020
1 parent a8db1f7 commit 6c4aacf
Show file tree
Hide file tree
Showing 60 changed files with 455 additions and 659 deletions.
7 changes: 3 additions & 4 deletions .eslintrc → .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,9 @@
},
"ignorePatterns": ["**/*.ts"],
"plugins": ["@typescript-eslint", "@nrwl/nx"],
"extends": [
],
"extends": [],
"rules": {
"@typescript-eslint/explicit-module-boundary-types": "off"
},
"overrides": [
]
"overrides": []
}
4 changes: 2 additions & 2 deletions e2e/angular/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'angular',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-angular',
};
4 changes: 2 additions & 2 deletions e2e/bazel/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'bazel',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-bazel',
};
4 changes: 2 additions & 2 deletions e2e/cli/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'cli',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-cli',
};
4 changes: 2 additions & 2 deletions e2e/cypress/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'cypress',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-cypress',
};
4 changes: 2 additions & 2 deletions e2e/jest/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'jest',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-jest',
};
4 changes: 2 additions & 2 deletions e2e/linter/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'linter',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-linter',
};
4 changes: 2 additions & 2 deletions e2e/next/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'next',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-next',
};
4 changes: 2 additions & 2 deletions e2e/node/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'node',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-node',
};
4 changes: 2 additions & 2 deletions e2e/nx-plugin/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'nx-plugin',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-nx-plugin',
};
4 changes: 2 additions & 2 deletions e2e/react/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'react',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-react',
};
4 changes: 2 additions & 2 deletions e2e/storybook/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'storybook',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-storybook',
};
4 changes: 2 additions & 2 deletions e2e/web/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'web',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-web',
};
4 changes: 2 additions & 2 deletions e2e/workspace/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module.exports = {
name: 'workspace',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
maxWorkers: 1,
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'e2e-workspace',
};
29 changes: 21 additions & 8 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,23 @@
module.exports = {
testMatch: ['**/+(*.)+(spec|test).+(ts|js)?(x)'],
transform: {
'^.+\\.(ts|js|html)$': 'ts-jest',
},
resolver: '../../scripts/patched-jest-resolver.js',
moduleFileExtensions: ['ts', 'js', 'html'],
coverageReporters: ['html'],
maxWorkers: 2,
projects: [
'<rootDir>/packages/tao',
'<rootDir>/packages/workspace',
'<rootDir>/packages/web',
'<rootDir>/packages/cypress',
'<rootDir>/packages/jest',
'<rootDir>/packages/storybook',
'<rootDir>/packages/react',
'<rootDir>/packages/nx-plugin',
'<rootDir>/packages/node',
'<rootDir>/packages/next',
'<rootDir>/packages/nest',
'<rootDir>/packages/linter',
'<rootDir>/packages/express',
'<rootDir>/packages/eslint-plugin-nx',
'<rootDir>/packages/create-nx-workspace',
'<rootDir>/packages/create-nx-plugin',
'<rootDir>/packages/cli',
'<rootDir>/packages/bazel',
'<rootDir>/packages/angular',
],
};
12 changes: 12 additions & 0 deletions jest.preset.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
const nxPreset = require('@nrwl/jest/preset');
module.exports = {
...nxPreset,
testMatch: ['**/+(*.)+(spec|test).+(ts|js)?(x)'],
transform: {
'^.+\\.(ts|js|html)$': 'ts-jest',
},
resolver: '../../scripts/patched-jest-resolver.js',
moduleFileExtensions: ['ts', 'js', 'html'],
coverageReporters: ['html'],
maxWorkers: 2,
};
3 changes: 2 additions & 1 deletion nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
},
"tsconfig.base.json": "*",
"tslint.json": "*",
"nx.json": "*"
"nx.json": "*",
".eslintrc.json": "*"
},
"tasksRunnerOptions": {
"default": {
Expand Down
16 changes: 9 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,12 @@
"@ngrx/store": "9.1.0",
"@ngrx/store-devtools": "9.1.0",
"@ngtools/webpack": "~10.1.3",
"@nrwl/eslint-plugin-nx": "10.2.1-beta.1",
"@nrwl/jest": "10.2.1-beta.1",
"@nrwl/node": "10.2.1-beta.1",
"@nrwl/nx-cloud": "^10.1.6",
"@nrwl/workspace": "10.2.1-beta.1",
"@nrwl/cli": "10.3.0-rc.3",
"@nrwl/eslint-plugin-nx": "10.3.0-rc.3",
"@nrwl/jest": "10.3.0-rc.3",
"@nrwl/node": "10.3.0-rc.3",
"@nrwl/nx-cloud": "10.1.6",
"@nrwl/workspace": "10.3.0-rc.3",
"@reduxjs/toolkit": "1.3.2",
"@rollup/plugin-babel": "5.0.2",
"@rollup/plugin-commonjs": "11.0.2",
Expand Down Expand Up @@ -220,7 +221,7 @@
"terser-webpack-plugin": "2.3.1",
"tmp": "0.0.33",
"tree-kill": "1.2.2",
"ts-jest": "26.1.4",
"ts-jest": "26.4.0",
"ts-loader": "5.4.5",
"ts-node": "^8.0.2",
"tsconfig-paths-webpack-plugin": "3.2.0",
Expand Down Expand Up @@ -253,5 +254,6 @@
"hooks": {
"pre-push": "yarn check-commit && yarn documentation && pretty-quick --check"
}
}
},
"dependencies": {}
}
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/angular/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'angular',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'angular',
};
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/bazel/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'bazel',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'bazel',
};
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/cli/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'cli',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'cli',
};
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/create-nx-plugin/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'create-nx-plugin',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'create-nx-plugin',
};
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/create-nx-workspace/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'create-nx-workspace',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'create-nx-workspace',
};
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/cypress/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'cypress',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'cypress',
};
File renamed without changes.
4 changes: 2 additions & 2 deletions packages/eslint-plugin-nx/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
module.exports = {
name: 'eslint-plugin-nx',
preset: '../../jest.config.js',
preset: '../../jest.preset.js',
transform: {
'^.+\\.[tj]sx?$': 'ts-jest',
},
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'html'],
globals: { 'ts-jest': { tsConfig: '<rootDir>/tsconfig.spec.json' } },
displayName: 'eslint-plugin-nx',
};
Loading

0 comments on commit 6c4aacf

Please sign in to comment.