Skip to content

Commit 465cfee

Browse files
fix(qwik-nx): nx 15.9 updates (#115)
* fix(qwik-nx): ensure all peer dependencies are installed * fix(qwik-nx): add missing @nrwl/* packages to qwik-nx to ensure they resolve correctly * chore: migrate repo to latest nx --------- Co-authored-by: Jack Hsu <[email protected]>
1 parent 1df2c8c commit 465cfee

File tree

14 files changed

+299
-338
lines changed

14 files changed

+299
-338
lines changed

e2e/qwik-nx-e2e/tests/chore.spec.ts

+3
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ describe('appGenerator e2e', () => {
2727

2828
expect(packageJson.dependencies).toBeUndefined();
2929
expect(packageJson.peerDependencies).toEqual({
30+
'@nrwl/devkit': '^15.8.0',
31+
'@nrwl/js': '^15.8.0',
32+
'@nrwl/linter': '^15.8.0',
3033
'@nrwl/vite': '^15.8.0',
3134
tslib: '^2.3.0',
3235
});

package.json

+12-12
Original file line numberDiff line numberDiff line change
@@ -18,17 +18,17 @@
1818
"@commitlint/config-angular": "^17.3.0",
1919
"@commitlint/config-conventional": "^17.3.0",
2020
"@jscutlery/semver": "^2.29.0",
21-
"@nrwl/cli": "15.8.2",
22-
"@nrwl/cypress": "15.8.2",
23-
"@nrwl/devkit": "15.8.2",
24-
"@nrwl/eslint-plugin-nx": "15.8.2",
25-
"@nrwl/jest": "15.8.2",
26-
"@nrwl/js": "15.8.2",
27-
"@nrwl/linter": "15.8.2",
28-
"@nrwl/nx-plugin": "15.8.2",
29-
"@nrwl/storybook": "15.8.2",
30-
"@nrwl/vite": "15.8.2",
31-
"@nrwl/workspace": "15.8.2",
21+
"@nrwl/cli": "15.9.2",
22+
"@nrwl/cypress": "15.9.2",
23+
"@nrwl/devkit": "15.9.2",
24+
"@nrwl/eslint-plugin-nx": "15.9.2",
25+
"@nrwl/jest": "15.9.2",
26+
"@nrwl/js": "15.9.2",
27+
"@nrwl/linter": "15.9.2",
28+
"@nrwl/nx-plugin": "15.9.2",
29+
"@nrwl/storybook": "15.9.2",
30+
"@nrwl/vite": "15.9.2",
31+
"@nrwl/workspace": "15.9.2",
3232
"@nxkit/playwright": "^2.1.2",
3333
"@swc-node/register": "^1.4.2",
3434
"@swc/cli": "~0.1.55",
@@ -55,7 +55,7 @@
5555
"jsonc-eslint-parser": "^2.1.0",
5656
"kill-port": "2.0.1",
5757
"ngx-deploy-npm": "^5.2.0",
58-
"nx": "15.8.2",
58+
"nx": "15.9.2",
5959
"prettier": "^2.8.0",
6060
"pretty-quick": "^3.1.3",
6161
"tcp-port-used": "1.0.2",

packages/qwik-nx/package.json

+5-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,11 @@
2222
"generators": "./generators.json",
2323
"executors": "./executors.json",
2424
"peerDependencies": {
25-
"@nrwl/vite": "^15.8.0"
25+
"@nrwl/devkit": "^15.8.0",
26+
"@nrwl/js": "^15.8.0",
27+
"@nrwl/linter": "^15.8.0",
28+
"@nrwl/vite": "^15.8.0",
29+
"tslib": "^2.3.0"
2630
},
2731
"nx-migrations": {
2832
"migrations": "./migrations.json"

packages/qwik-nx/src/generators/application/__snapshots__/generator.spec.ts.snap

+14-14
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,16 @@ export default defineConfig({
1111
cacheDir: '../../node_modules/.vite/apps/myapp',
1212
plugins: [
1313
qwikNxVite(),
14-
qwikCity(),
14+
qwikCity(),
1515
qwikVite({
16-
client: {
17-
outDir: '../../dist/apps/myapp/client',
18-
},
19-
ssr: {
20-
outDir: '../../dist/apps/myapp/server',
21-
},
22-
}),
23-
tsconfigPaths({ root: '../../' })
16+
client: {
17+
outDir: '../../dist/apps/myapp/client',
18+
},
19+
ssr: {
20+
outDir: '../../dist/apps/myapp/server',
21+
},
22+
}),
23+
tsconfigPaths({ root: '../../' }),
2424
],
2525
server: {
2626
fs: {
@@ -33,7 +33,6 @@ export default defineConfig({
3333
'Cache-Control': 'public, max-age=600',
3434
},
3535
},
36-
3736
});
3837
"
3938
`;
@@ -48,10 +47,7 @@ exports[`qwik-nx generator should run successfully 2`] = `
4847
\\"build\\": {
4948
\\"executor\\": \\"qwik-nx:build\\",
5049
\\"options\\": {
51-
\\"runSequence\\": [
52-
\\"myapp:build.client\\",
53-
\\"myapp:build.ssr\\"
54-
],
50+
\\"runSequence\\": [\\"myapp:build.client\\", \\"myapp:build.ssr\\"],
5551
\\"outputPath\\": \\"dist/apps/myapp\\"
5652
},
5753
\\"configurations\\": {
@@ -132,6 +128,10 @@ Array [
132128
"path": "libs/.gitignore",
133129
"type": "CREATE",
134130
},
131+
Object {
132+
"path": ".prettierignore",
133+
"type": "CREATE",
134+
},
135135
Object {
136136
"path": "apps/myapp/project.json",
137137
"type": "CREATE",

packages/qwik-nx/src/generators/host/__snapshots__/generator.spec.ts.snap

+46-60
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,16 @@ export default defineConfig({
1111
cacheDir: '../../node_modules/.vite/apps/myhostapp',
1212
plugins: [
1313
qwikNxVite(),
14-
qwikCity(),
14+
qwikCity(),
1515
qwikVite({
16-
client: {
17-
outDir: '../../dist/apps/myhostapp/client',
18-
},
19-
ssr: {
20-
outDir: '../../dist/apps/myhostapp/server',
21-
},
22-
}),
23-
tsconfigPaths({ root: '../../' })
16+
client: {
17+
outDir: '../../dist/apps/myhostapp/client',
18+
},
19+
ssr: {
20+
outDir: '../../dist/apps/myhostapp/server',
21+
},
22+
}),
23+
tsconfigPaths({ root: '../../' }),
2424
],
2525
server: {
2626
fs: {
@@ -33,15 +33,14 @@ export default defineConfig({
3333
'Cache-Control': 'public, max-age=600',
3434
},
3535
},
36-
test: {
36+
test: {
3737
globals: true,
3838
cache: {
3939
dir: '../../node_modules/.vitest',
4040
},
4141
environment: 'node',
42-
include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}']
43-
}
44-
42+
include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
43+
},
4544
});
4645
"
4746
`;
@@ -104,10 +103,7 @@ exports[`host generator should run successfully 3`] = `
104103
\\"build\\": {
105104
\\"executor\\": \\"qwik-nx:build\\",
106105
\\"options\\": {
107-
\\"runSequence\\": [
108-
\\"myhostapp:build.client\\",
109-
\\"myhostapp:build.ssr\\"
110-
],
106+
\\"runSequence\\": [\\"myhostapp:build.client\\", \\"myhostapp:build.ssr\\"],
111107
\\"outputPath\\": \\"dist/apps/myhostapp\\"
112108
},
113109
\\"configurations\\": {
@@ -143,9 +139,7 @@ exports[`host generator should run successfully 3`] = `
143139
},
144140
\\"test\\": {
145141
\\"executor\\": \\"@nrwl/vite:test\\",
146-
\\"outputs\\": [
147-
\\"../../coverage/apps/myhostapp\\"
148-
],
142+
\\"outputs\\": [\\"../../coverage/apps/myhostapp\\"],
149143
\\"options\\": {
150144
\\"passWithNoTests\\": true,
151145
\\"reportsDirectory\\": \\"../../coverage/apps/myhostapp\\"
@@ -198,6 +192,10 @@ Array [
198192
"path": "libs/.gitignore",
199193
"type": "CREATE",
200194
},
195+
Object {
196+
"path": ".prettierignore",
197+
"type": "CREATE",
198+
},
201199
Object {
202200
"path": "apps/myhostapp/project.json",
203201
"type": "CREATE",
@@ -508,16 +506,16 @@ export default defineConfig({
508506
cacheDir: '../../node_modules/.vite/apps/remote1',
509507
plugins: [
510508
qwikNxVite(),
511-
qwikCity(),
509+
qwikCity(),
512510
qwikVite({
513-
client: {
514-
outDir: '../../dist/apps/remote1/client',
515-
},
516-
ssr: {
517-
outDir: '../../dist/apps/remote1/server',
518-
},
519-
}),
520-
tsconfigPaths({ root: '../../' })
511+
client: {
512+
outDir: '../../dist/apps/remote1/client',
513+
},
514+
ssr: {
515+
outDir: '../../dist/apps/remote1/server',
516+
},
517+
}),
518+
tsconfigPaths({ root: '../../' }),
521519
],
522520
server: {
523521
fs: {
@@ -530,15 +528,14 @@ export default defineConfig({
530528
'Cache-Control': 'public, max-age=600',
531529
},
532530
},
533-
test: {
531+
test: {
534532
globals: true,
535533
cache: {
536534
dir: '../../node_modules/.vitest',
537535
},
538536
environment: 'node',
539-
include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}']
540-
}
541-
537+
include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
538+
},
542539
});
543540
"
544541
`;
@@ -599,10 +596,7 @@ exports[`host generator should run successfully 7`] = `
599596
\\"build\\": {
600597
\\"executor\\": \\"qwik-nx:build\\",
601598
\\"options\\": {
602-
\\"runSequence\\": [
603-
\\"remote1:build.client\\",
604-
\\"remote1:build.ssr\\"
605-
],
599+
\\"runSequence\\": [\\"remote1:build.client\\", \\"remote1:build.ssr\\"],
606600
\\"outputPath\\": \\"dist/apps/remote1\\"
607601
},
608602
\\"configurations\\": {
@@ -638,9 +632,7 @@ exports[`host generator should run successfully 7`] = `
638632
},
639633
\\"test\\": {
640634
\\"executor\\": \\"@nrwl/vite:test\\",
641-
\\"outputs\\": [
642-
\\"../../coverage/apps/remote1\\"
643-
],
635+
\\"outputs\\": [\\"../../coverage/apps/remote1\\"],
644636
\\"options\\": {
645637
\\"passWithNoTests\\": true,
646638
\\"reportsDirectory\\": \\"../../coverage/apps/remote1\\"
@@ -678,16 +670,16 @@ export default defineConfig({
678670
cacheDir: '../../node_modules/.vite/apps/remote2',
679671
plugins: [
680672
qwikNxVite(),
681-
qwikCity(),
673+
qwikCity(),
682674
qwikVite({
683-
client: {
684-
outDir: '../../dist/apps/remote2/client',
685-
},
686-
ssr: {
687-
outDir: '../../dist/apps/remote2/server',
688-
},
689-
}),
690-
tsconfigPaths({ root: '../../' })
675+
client: {
676+
outDir: '../../dist/apps/remote2/client',
677+
},
678+
ssr: {
679+
outDir: '../../dist/apps/remote2/server',
680+
},
681+
}),
682+
tsconfigPaths({ root: '../../' }),
691683
],
692684
server: {
693685
fs: {
@@ -700,15 +692,14 @@ export default defineConfig({
700692
'Cache-Control': 'public, max-age=600',
701693
},
702694
},
703-
test: {
695+
test: {
704696
globals: true,
705697
cache: {
706698
dir: '../../node_modules/.vitest',
707699
},
708700
environment: 'node',
709-
include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}']
710-
}
711-
701+
include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
702+
},
712703
});
713704
"
714705
`;
@@ -769,10 +760,7 @@ exports[`host generator should run successfully 10`] = `
769760
\\"build\\": {
770761
\\"executor\\": \\"qwik-nx:build\\",
771762
\\"options\\": {
772-
\\"runSequence\\": [
773-
\\"remote2:build.client\\",
774-
\\"remote2:build.ssr\\"
775-
],
763+
\\"runSequence\\": [\\"remote2:build.client\\", \\"remote2:build.ssr\\"],
776764
\\"outputPath\\": \\"dist/apps/remote2\\"
777765
},
778766
\\"configurations\\": {
@@ -808,9 +796,7 @@ exports[`host generator should run successfully 10`] = `
808796
},
809797
\\"test\\": {
810798
\\"executor\\": \\"@nrwl/vite:test\\",
811-
\\"outputs\\": [
812-
\\"../../coverage/apps/remote2\\"
813-
],
799+
\\"outputs\\": [\\"../../coverage/apps/remote2\\"],
814800
\\"options\\": {
815801
\\"passWithNoTests\\": true,
816802
\\"reportsDirectory\\": \\"../../coverage/apps/remote2\\"

0 commit comments

Comments
 (0)