@nx/node 23.0.0-beta.5 → 23.0.0-beta.6
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/package.json +7 -7
- package/src/generators/application/application.d.ts.map +1 -1
- package/src/generators/application/application.js +3 -3
- package/src/generators/application/lib/create-project.d.ts.map +1 -1
- package/src/generators/application/lib/create-project.js +3 -3
- package/src/generators/application/lib/normalize-options.js +3 -3
- package/src/generators/e2e-project/e2e-project.d.ts.map +1 -1
- package/src/generators/e2e-project/e2e-project.js +3 -4
- package/src/generators/library/library.d.ts.map +1 -1
- package/src/generators/library/library.js +4 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nx/node",
|
|
3
|
-
"version": "23.0.0-beta.
|
|
3
|
+
"version": "23.0.0-beta.6",
|
|
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": {
|
|
@@ -33,16 +33,16 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"tslib": "^2.3.0",
|
|
36
|
-
"@nx/devkit": "23.0.0-beta.
|
|
37
|
-
"@nx/jest": "23.0.0-beta.
|
|
38
|
-
"@nx/js": "23.0.0-beta.
|
|
39
|
-
"@nx/eslint": "23.0.0-beta.
|
|
40
|
-
"@nx/docker": "23.0.0-beta.
|
|
36
|
+
"@nx/devkit": "23.0.0-beta.6",
|
|
37
|
+
"@nx/jest": "23.0.0-beta.6",
|
|
38
|
+
"@nx/js": "23.0.0-beta.6",
|
|
39
|
+
"@nx/eslint": "23.0.0-beta.6",
|
|
40
|
+
"@nx/docker": "23.0.0-beta.6",
|
|
41
41
|
"tcp-port-used": "^1.0.2",
|
|
42
42
|
"kill-port": "^1.6.1"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"nx": "23.0.0-beta.
|
|
45
|
+
"nx": "23.0.0-beta.6"
|
|
46
46
|
},
|
|
47
47
|
"publishConfig": {
|
|
48
48
|
"access": "public"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"application.d.ts","sourceRoot":"","sources":["../../../../../../packages/node/src/generators/application/application.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"application.d.ts","sourceRoot":"","sources":["../../../../../../packages/node/src/generators/application/application.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,iBAAiB,EAIjB,IAAI,EAIL,MAAM,YAAY,CAAC;AAapB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAwClC,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,8BAMpE;AAED,wBAAsB,4BAA4B,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,8BAwL5E;AAED,eAAe,oBAAoB,CAAC"}
|
|
@@ -35,12 +35,12 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
36
|
exports.applicationGenerator = applicationGenerator;
|
|
37
37
|
exports.applicationGeneratorInternal = applicationGeneratorInternal;
|
|
38
|
+
const internal_1 = require("@nx/devkit/internal");
|
|
38
39
|
const devkit_1 = require("@nx/devkit");
|
|
39
40
|
const jest_1 = require("@nx/jest");
|
|
40
41
|
const js_1 = require("@nx/js");
|
|
41
42
|
const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
|
|
42
43
|
const sort_fields_1 = require("@nx/js/src/utils/package-json/sort-fields");
|
|
43
|
-
const log_show_project_command_1 = require("@nx/devkit/src/utils/log-show-project-command");
|
|
44
44
|
const versions_1 = require("../../utils/versions");
|
|
45
45
|
const e2e_project_1 = require("../e2e-project/e2e-project");
|
|
46
46
|
const init_1 = require("../init/init");
|
|
@@ -111,7 +111,7 @@ async function applicationGeneratorInternal(tree, schema) {
|
|
|
111
111
|
return (0, devkit_1.runTasksInSerial)(...[
|
|
112
112
|
...tasks,
|
|
113
113
|
() => {
|
|
114
|
-
(0,
|
|
114
|
+
(0, internal_1.logShowProjectCommand)(options.name);
|
|
115
115
|
},
|
|
116
116
|
]);
|
|
117
117
|
}
|
|
@@ -218,7 +218,7 @@ async function applicationGeneratorInternal(tree, schema) {
|
|
|
218
218
|
await (0, devkit_1.formatFiles)(tree);
|
|
219
219
|
}
|
|
220
220
|
tasks.push(() => {
|
|
221
|
-
(0,
|
|
221
|
+
(0, internal_1.logShowProjectCommand)(options.name);
|
|
222
222
|
});
|
|
223
223
|
return (0, devkit_1.runTasksInSerial)(...tasks);
|
|
224
224
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-project.d.ts","sourceRoot":"","sources":["../../../../../../../packages/node/src/generators/application/lib/create-project.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"create-project.d.ts","sourceRoot":"","sources":["../../../../../../../packages/node/src/generators/application/lib/create-project.ts"],"names":[],"mappings":"AACA,OAAO,EAIL,IAAI,EAEL,MAAM,YAAY,CAAC;AAIpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AASvD,wBAAgB,UAAU,CACxB,IAAI,EAAE,IAAI,EACV,OAAO,EAAE,gBAAgB,EACzB,qBAAqB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,QA8D9C"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.addProject = addProject;
|
|
4
|
+
const internal_1 = require("@nx/devkit/internal");
|
|
4
5
|
const devkit_1 = require("@nx/devkit");
|
|
5
|
-
const target_defaults_utils_1 = require("@nx/devkit/src/generators/target-defaults-utils");
|
|
6
6
|
const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
|
|
7
7
|
const has_webpack_plugin_1 = require("../../../utils/has-webpack-plugin");
|
|
8
8
|
const create_targets_1 = require("./create-targets");
|
|
@@ -15,14 +15,14 @@ function addProject(tree, options, frameworkDependencies) {
|
|
|
15
15
|
tags: options.parsedTags,
|
|
16
16
|
};
|
|
17
17
|
if (options.bundler === 'esbuild') {
|
|
18
|
-
(0,
|
|
18
|
+
(0, internal_1.addBuildTargetDefaults)(tree, '@nx/esbuild:esbuild', 'build', [
|
|
19
19
|
ts_solution_setup_1.TS_SOLUTION_SETUP_TSCONFIG_INPUT,
|
|
20
20
|
]);
|
|
21
21
|
project.targets.build = (0, create_targets_1.getEsBuildConfig)(tree, project, options);
|
|
22
22
|
}
|
|
23
23
|
else if (options.bundler === 'webpack') {
|
|
24
24
|
if (!(0, has_webpack_plugin_1.hasWebpackPlugin)(tree) && options.addPlugin === false) {
|
|
25
|
-
(0,
|
|
25
|
+
(0, internal_1.addBuildTargetDefaults)(tree, `@nx/webpack:webpack`, 'build', [
|
|
26
26
|
ts_solution_setup_1.TS_SOLUTION_SETUP_TSCONFIG_INPUT,
|
|
27
27
|
]);
|
|
28
28
|
project.targets.build = (0, create_targets_1.getWebpackBuildConfig)(tree, project, options);
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.normalizeOptions = normalizeOptions;
|
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
|
5
|
-
const
|
|
5
|
+
const internal_1 = require("@nx/devkit/internal");
|
|
6
6
|
const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
|
|
7
7
|
async function normalizeOptions(host, options) {
|
|
8
|
-
await (0,
|
|
9
|
-
const { projectName, projectRoot: appProjectRoot, importPath, } = await (0,
|
|
8
|
+
await (0, internal_1.ensureRootProjectName)(options, 'application');
|
|
9
|
+
const { projectName, projectRoot: appProjectRoot, importPath, } = await (0, internal_1.determineProjectNameAndRootOptions)(host, {
|
|
10
10
|
name: options.name,
|
|
11
11
|
projectType: 'application',
|
|
12
12
|
directory: options.directory,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"e2e-project.d.ts","sourceRoot":"","sources":["../../../../../../packages/node/src/generators/e2e-project/e2e-project.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"e2e-project.d.ts","sourceRoot":"","sources":["../../../../../../packages/node/src/generators/e2e-project/e2e-project.ts"],"names":[],"mappings":"AAIA,OAAO,EAKL,iBAAiB,EAOjB,IAAI,EAGL,MAAM,YAAY,CAAC;AAQpB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAgBlC,wBAAsB,mBAAmB,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,8BAMpE;AAED,wBAAsB,2BAA2B,CAC/C,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,MAAM,8BAyPjB;AAgDD,eAAe,mBAAmB,CAAC"}
|
|
@@ -3,14 +3,13 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.e2eProjectGenerator = e2eProjectGenerator;
|
|
4
4
|
exports.e2eProjectGeneratorInternal = e2eProjectGeneratorInternal;
|
|
5
5
|
const tslib_1 = require("tslib");
|
|
6
|
+
const internal_1 = require("@nx/devkit/internal");
|
|
6
7
|
const devkit_1 = require("@nx/devkit");
|
|
7
|
-
const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
|
|
8
8
|
const eslint_1 = require("@nx/eslint");
|
|
9
9
|
const global_eslint_config_1 = require("@nx/eslint/src/generators/init/global-eslint-config");
|
|
10
10
|
const path = tslib_1.__importStar(require("path"));
|
|
11
11
|
const versions_1 = require("../../utils/versions");
|
|
12
12
|
const eslint_file_1 = require("@nx/eslint/src/generators/utils/eslint-file");
|
|
13
|
-
const log_show_project_command_1 = require("@nx/devkit/src/utils/log-show-project-command");
|
|
14
13
|
const config_file_1 = require("@nx/jest/src/utils/config/config-file");
|
|
15
14
|
const versions_2 = require("@nx/jest/src/utils/versions");
|
|
16
15
|
const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
|
|
@@ -209,7 +208,7 @@ async function e2eProjectGeneratorInternal(host, _options) {
|
|
|
209
208
|
await (0, devkit_1.formatFiles)(host);
|
|
210
209
|
}
|
|
211
210
|
tasks.push(() => {
|
|
212
|
-
(0,
|
|
211
|
+
(0, internal_1.logShowProjectCommand)(options.e2eProjectName);
|
|
213
212
|
});
|
|
214
213
|
return (0, devkit_1.runTasksInSerial)(...tasks);
|
|
215
214
|
}
|
|
@@ -219,7 +218,7 @@ async function normalizeOptions(tree, options) {
|
|
|
219
218
|
const projectConfig = (0, devkit_1.readProjectConfiguration)(tree, options.project);
|
|
220
219
|
directory = `${projectConfig.root}-e2e`;
|
|
221
220
|
}
|
|
222
|
-
const { projectName: e2eProjectName, projectRoot: e2eProjectRoot, importPath, } = await (0,
|
|
221
|
+
const { projectName: e2eProjectName, projectRoot: e2eProjectRoot, importPath, } = await (0, internal_1.determineProjectNameAndRootOptions)(tree, {
|
|
223
222
|
name: options.name,
|
|
224
223
|
projectType: 'application',
|
|
225
224
|
directory,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"library.d.ts","sourceRoot":"","sources":["../../../../../../packages/node/src/generators/library/library.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"library.d.ts","sourceRoot":"","sources":["../../../../../../packages/node/src/generators/library/library.ts"],"names":[],"mappings":"AAKA,OAAO,EAIL,iBAAiB,EAUjB,IAAI,EAIL,MAAM,YAAY,CAAC;AAOpB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAQlC,MAAM,WAAW,gBAAiB,SAAQ,MAAM;IAC9C,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,QAAQ,EAAE,KAAK,GAAG,KAAK,CAAC;IACxB,uBAAuB,EAAE,OAAO,CAAC;CAClC;AAED,wBAAsB,gBAAgB,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,8BAMhE;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,8BA2ExE;AAED,eAAe,gBAAgB,CAAC"}
|
|
@@ -2,15 +2,14 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.libraryGenerator = libraryGenerator;
|
|
4
4
|
exports.libraryGeneratorInternal = libraryGeneratorInternal;
|
|
5
|
+
const internal_1 = require("@nx/devkit/internal");
|
|
5
6
|
const devkit_1 = require("@nx/devkit");
|
|
6
|
-
const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
|
|
7
7
|
const js_1 = require("@nx/js");
|
|
8
8
|
const add_swc_config_1 = require("@nx/js/src/utils/swc/add-swc-config");
|
|
9
9
|
const add_swc_dependencies_1 = require("@nx/js/src/utils/swc/add-swc-dependencies");
|
|
10
10
|
const path_1 = require("path");
|
|
11
11
|
const versions_1 = require("../../utils/versions");
|
|
12
12
|
const init_1 = require("../init/init");
|
|
13
|
-
const target_defaults_utils_1 = require("@nx/devkit/src/generators/target-defaults-utils");
|
|
14
13
|
const ts_solution_setup_1 = require("@nx/js/src/utils/typescript/ts-solution-setup");
|
|
15
14
|
const sort_fields_1 = require("@nx/js/src/utils/package-json/sort-fields");
|
|
16
15
|
async function libraryGenerator(tree, schema) {
|
|
@@ -75,8 +74,8 @@ async function libraryGeneratorInternal(tree, schema) {
|
|
|
75
74
|
}
|
|
76
75
|
exports.default = libraryGenerator;
|
|
77
76
|
async function normalizeOptions(tree, options) {
|
|
78
|
-
await (0,
|
|
79
|
-
const { projectName, names: projectNames, projectRoot, importPath, } = await (0,
|
|
77
|
+
await (0, internal_1.ensureRootProjectName)(options, 'library');
|
|
78
|
+
const { projectName, names: projectNames, projectRoot, importPath, } = await (0, internal_1.determineProjectNameAndRootOptions)(tree, {
|
|
80
79
|
name: options.name,
|
|
81
80
|
projectType: 'library',
|
|
82
81
|
directory: options.directory,
|
|
@@ -132,7 +131,7 @@ function updateProject(tree, options) {
|
|
|
132
131
|
const project = (0, devkit_1.readProjectConfiguration)(tree, options.projectName);
|
|
133
132
|
const rootProject = options.projectRoot === '.' || options.projectRoot === '';
|
|
134
133
|
project.targets = project.targets || {};
|
|
135
|
-
(0,
|
|
134
|
+
(0, internal_1.addBuildTargetDefaults)(tree, `@nx/js:${options.compiler}`);
|
|
136
135
|
// For TS solution, we want tsc build to be inferred by `@nx/js/typescript` plugin.
|
|
137
136
|
if (!options.isUsingTsSolutionConfig || options.compiler === 'swc') {
|
|
138
137
|
project.targets.build = {
|