@nx/node 0.0.0-pr-29771-5e92bcc → 0.0.0-pr-29750-cc9549c
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/migrations.json +0 -29
- package/package.json +5 -5
- package/src/generators/application/application.js +1 -4
- package/src/generators/application/schema.json +2 -1
- package/src/generators/e2e-project/files/ts-solution/tsconfig.json__tmpl__ +3 -1
- package/src/generators/library/library.js +7 -10
- package/src/utils/versions.d.ts +6 -6
- package/src/utils/versions.js +6 -6
package/migrations.json
CHANGED
|
@@ -18,35 +18,6 @@
|
|
|
18
18
|
"alwaysAddToPackageJson": false
|
|
19
19
|
}
|
|
20
20
|
}
|
|
21
|
-
},
|
|
22
|
-
"20.4.0": {
|
|
23
|
-
"version": "20.4.0-beta.3",
|
|
24
|
-
"packages": {
|
|
25
|
-
"fastify": {
|
|
26
|
-
"version": "~5.2.1",
|
|
27
|
-
"alwaysAddToPackageJson": false
|
|
28
|
-
},
|
|
29
|
-
"fastify-plugin": {
|
|
30
|
-
"version": "~5.0.1",
|
|
31
|
-
"alwaysAddToPackageJson": false
|
|
32
|
-
},
|
|
33
|
-
"@fastify/autoload": {
|
|
34
|
-
"version": "~6.0.3",
|
|
35
|
-
"alwaysAddToPackageJson": false
|
|
36
|
-
},
|
|
37
|
-
"@fastify/sensible": {
|
|
38
|
-
"version": "~6.0.2",
|
|
39
|
-
"alwaysAddToPackageJson": false
|
|
40
|
-
},
|
|
41
|
-
"express": {
|
|
42
|
-
"version": "^4.21.2",
|
|
43
|
-
"alwaysAddToPackageJson": false
|
|
44
|
-
},
|
|
45
|
-
"@types/express": {
|
|
46
|
-
"version": "^4.17.21",
|
|
47
|
-
"alwaysAddToPackageJson": false
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
21
|
}
|
|
51
22
|
}
|
|
52
23
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nx/node",
|
|
3
|
-
"version": "0.0.0-pr-
|
|
3
|
+
"version": "0.0.0-pr-29750-cc9549c",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "The Node Plugin for Nx contains generators to manage Node applications within an Nx workspace.",
|
|
6
6
|
"repository": {
|
|
@@ -32,10 +32,10 @@
|
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"tslib": "^2.3.0",
|
|
35
|
-
"@nx/devkit": "0.0.0-pr-
|
|
36
|
-
"@nx/jest": "0.0.0-pr-
|
|
37
|
-
"@nx/js": "0.0.0-pr-
|
|
38
|
-
"@nx/eslint": "0.0.0-pr-
|
|
35
|
+
"@nx/devkit": "0.0.0-pr-29750-cc9549c",
|
|
36
|
+
"@nx/jest": "0.0.0-pr-29750-cc9549c",
|
|
37
|
+
"@nx/js": "0.0.0-pr-29750-cc9549c",
|
|
38
|
+
"@nx/eslint": "0.0.0-pr-29750-cc9549c"
|
|
39
39
|
},
|
|
40
40
|
"publishConfig": {
|
|
41
41
|
"access": "public"
|
|
@@ -467,8 +467,6 @@ async function normalizeOptions(host, options) {
|
|
|
467
467
|
const nxJson = (0, devkit_1.readNxJson)(host);
|
|
468
468
|
const addPlugin = process.env.NX_ADD_PLUGINS !== 'false' &&
|
|
469
469
|
nxJson.useInferencePlugins !== false;
|
|
470
|
-
const isUsingTsSolutionConfig = (0, ts_solution_setup_1.isUsingTsSolutionSetup)(host);
|
|
471
|
-
const swcJest = options.swcJest ?? isUsingTsSolutionConfig;
|
|
472
470
|
return {
|
|
473
471
|
addPlugin,
|
|
474
472
|
...options,
|
|
@@ -483,8 +481,7 @@ async function normalizeOptions(host, options) {
|
|
|
483
481
|
rootProject: options.rootProject ?? false,
|
|
484
482
|
port: options.port ?? 3000,
|
|
485
483
|
outputPath: (0, devkit_1.joinPathFragments)('dist', options.rootProject ? options.name : appProjectRoot),
|
|
486
|
-
isUsingTsSolutionConfig,
|
|
487
|
-
swcJest,
|
|
484
|
+
isUsingTsSolutionConfig: (0, ts_solution_setup_1.isUsingTsSolutionSetup)(host),
|
|
488
485
|
};
|
|
489
486
|
}
|
|
490
487
|
exports.default = applicationGenerator;
|
|
@@ -69,7 +69,8 @@
|
|
|
69
69
|
},
|
|
70
70
|
"swcJest": {
|
|
71
71
|
"type": "boolean",
|
|
72
|
-
"description": "Use `@swc/jest` instead `ts-jest` for faster test compilation."
|
|
72
|
+
"description": "Use `@swc/jest` instead `ts-jest` for faster test compilation.",
|
|
73
|
+
"default": false
|
|
73
74
|
},
|
|
74
75
|
"babelJest": {
|
|
75
76
|
"type": "boolean",
|
|
@@ -22,11 +22,6 @@ async function libraryGenerator(tree, schema) {
|
|
|
22
22
|
}
|
|
23
23
|
async function libraryGeneratorInternal(tree, schema) {
|
|
24
24
|
const options = await normalizeOptions(tree, schema);
|
|
25
|
-
// If we are using the new TS solution
|
|
26
|
-
// We need to update the workspace file (package.json or pnpm-workspaces.yaml) to include the new project
|
|
27
|
-
if (options.isUsingTsSolutionConfig) {
|
|
28
|
-
(0, ts_solution_setup_1.addProjectToTsSolutionWorkspace)(tree, options.projectRoot);
|
|
29
|
-
}
|
|
30
25
|
const tasks = [];
|
|
31
26
|
if (options.publishable === true && !schema.importPath) {
|
|
32
27
|
throw new Error(`For publishable libs you have to provide a proper "--importPath" which needs to be a valid npm package name (e.g. my-awesome-lib or @myorg/my-lib)`);
|
|
@@ -67,6 +62,11 @@ async function libraryGeneratorInternal(tree, schema) {
|
|
|
67
62
|
if (options.isUsingTsSolutionConfig) {
|
|
68
63
|
tasks.push(() => (0, devkit_1.installPackagesTask)(tree, true));
|
|
69
64
|
}
|
|
65
|
+
// If we are using the new TS solution
|
|
66
|
+
// We need to update the workspace file (package.json or pnpm-workspaces.yaml) to include the new project
|
|
67
|
+
if (options.isUsingTsSolutionConfig) {
|
|
68
|
+
(0, ts_solution_setup_1.addProjectToTsSolutionWorkspace)(tree, options.projectRoot);
|
|
69
|
+
}
|
|
70
70
|
(0, sort_fields_1.sortPackageJsonFields)(tree, options.projectRoot);
|
|
71
71
|
if (!schema.skipFormat) {
|
|
72
72
|
await (0, devkit_1.formatFiles)(tree);
|
|
@@ -92,17 +92,14 @@ async function normalizeOptions(tree, options) {
|
|
|
92
92
|
const parsedTags = options.tags
|
|
93
93
|
? options.tags.split(',').map((s) => s.trim())
|
|
94
94
|
: [];
|
|
95
|
-
const isUsingTsSolutionConfig = (0, ts_solution_setup_1.isUsingTsSolutionSetup)(tree);
|
|
96
95
|
return {
|
|
97
96
|
...options,
|
|
98
97
|
fileName,
|
|
99
|
-
projectName
|
|
100
|
-
? (0, get_import_path_1.getImportPath)(tree, projectName)
|
|
101
|
-
: projectName,
|
|
98
|
+
projectName,
|
|
102
99
|
projectRoot,
|
|
103
100
|
parsedTags,
|
|
104
101
|
importPath,
|
|
105
|
-
isUsingTsSolutionConfig,
|
|
102
|
+
isUsingTsSolutionConfig: (0, ts_solution_setup_1.isUsingTsSolutionSetup)(tree),
|
|
106
103
|
};
|
|
107
104
|
}
|
|
108
105
|
function createFiles(tree, options) {
|
package/src/utils/versions.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
export declare const nxVersion: any;
|
|
2
2
|
export declare const tslibVersion = "^2.3.0";
|
|
3
3
|
export declare const typesNodeVersion = "~18.16.9";
|
|
4
|
-
export declare const expressVersion = "
|
|
5
|
-
export declare const expressTypingsVersion = "
|
|
4
|
+
export declare const expressVersion = "~4.18.1";
|
|
5
|
+
export declare const expressTypingsVersion = "~4.17.13";
|
|
6
6
|
export declare const koaVersion = "~2.14.1";
|
|
7
7
|
export declare const koaTypingsVersion = "~2.13.5";
|
|
8
|
-
export declare const fastifyVersion = "~
|
|
9
|
-
export declare const fastifyAutoloadVersion = "~
|
|
10
|
-
export declare const fastifySensibleVersion = "~
|
|
11
|
-
export declare const fastifyPluginVersion = "~5.0
|
|
8
|
+
export declare const fastifyVersion = "~4.13.0";
|
|
9
|
+
export declare const fastifyAutoloadVersion = "~5.7.1";
|
|
10
|
+
export declare const fastifySensibleVersion = "~5.2.0";
|
|
11
|
+
export declare const fastifyPluginVersion = "~4.5.0";
|
|
12
12
|
export declare const axiosVersion = "^1.6.0";
|
package/src/utils/versions.js
CHANGED
|
@@ -4,12 +4,12 @@ exports.axiosVersion = exports.fastifyPluginVersion = exports.fastifySensibleVer
|
|
|
4
4
|
exports.nxVersion = require('../../package.json').version;
|
|
5
5
|
exports.tslibVersion = '^2.3.0';
|
|
6
6
|
exports.typesNodeVersion = '~18.16.9';
|
|
7
|
-
exports.expressVersion = '
|
|
8
|
-
exports.expressTypingsVersion = '
|
|
7
|
+
exports.expressVersion = '~4.18.1';
|
|
8
|
+
exports.expressTypingsVersion = '~4.17.13';
|
|
9
9
|
exports.koaVersion = '~2.14.1';
|
|
10
10
|
exports.koaTypingsVersion = '~2.13.5';
|
|
11
|
-
exports.fastifyVersion = '~
|
|
12
|
-
exports.fastifyAutoloadVersion = '~
|
|
13
|
-
exports.fastifySensibleVersion = '~
|
|
14
|
-
exports.fastifyPluginVersion = '~5.0
|
|
11
|
+
exports.fastifyVersion = '~4.13.0';
|
|
12
|
+
exports.fastifyAutoloadVersion = '~5.7.1';
|
|
13
|
+
exports.fastifySensibleVersion = '~5.2.0';
|
|
14
|
+
exports.fastifyPluginVersion = '~4.5.0';
|
|
15
15
|
exports.axiosVersion = '^1.6.0';
|