@nx/esbuild 19.4.3 → 19.5.0-beta.1

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/esbuild",
3
- "version": "19.4.3",
3
+ "version": "19.5.0-beta.1",
4
4
  "private": false,
5
5
  "description": "The Nx Plugin for esbuild contains executors and generators that support building applications using esbuild",
6
6
  "repository": {
@@ -36,9 +36,9 @@
36
36
  "fs-extra": "^11.1.0",
37
37
  "tslib": "^2.3.0",
38
38
  "tsconfig-paths": "^4.1.2",
39
- "@nx/devkit": "19.4.3",
40
- "@nx/js": "19.4.3",
41
- "@nrwl/esbuild": "19.4.3"
39
+ "@nx/devkit": "19.5.0-beta.1",
40
+ "@nx/js": "19.5.0-beta.1",
41
+ "@nrwl/esbuild": "19.5.0-beta.1"
42
42
  },
43
43
  "peerDependencies": {
44
44
  "esbuild": "~0.19.2"
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.esbuildExecutor = void 0;
3
+ exports.esbuildExecutor = esbuildExecutor;
4
4
  const chalk = require("chalk");
5
5
  const devkit_1 = require("@nx/devkit");
6
6
  const js_1 = require("@nx/js");
@@ -141,7 +141,6 @@ async function* esbuildExecutor(_options, context) {
141
141
  }
142
142
  }
143
143
  }
144
- exports.esbuildExecutor = esbuildExecutor;
145
144
  function getTypeCheckOptions(options, context) {
146
145
  const { watch, tsConfig, outputPath } = options;
147
146
  const typeCheckOptions = {
@@ -1,6 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getRegisterFileContent = exports.getOutfile = exports.getOutExtension = exports.buildEsbuildOptions = void 0;
3
+ exports.buildEsbuildOptions = buildEsbuildOptions;
4
+ exports.getOutExtension = getOutExtension;
5
+ exports.getOutfile = getOutfile;
6
+ exports.getRegisterFileContent = getRegisterFileContent;
4
7
  const path = require("path");
5
8
  const fs_1 = require("fs");
6
9
  const devkit_1 = require("@nx/devkit");
@@ -96,7 +99,6 @@ function buildEsbuildOptions(format, options, context) {
96
99
  }
97
100
  return esbuildOptions;
98
101
  }
99
- exports.buildEsbuildOptions = buildEsbuildOptions;
100
102
  function getOutExtension(format, options) {
101
103
  const userDefinedExt = options.userDefinedBuildOptions?.outExtension?.['.js'];
102
104
  // Allow users to change the output extensions from default CJS and ESM extensions.
@@ -110,14 +112,12 @@ function getOutExtension(format, options) {
110
112
  ? ESM_FILE_EXTENSION
111
113
  : CJS_FILE_EXTENSION;
112
114
  }
113
- exports.getOutExtension = getOutExtension;
114
115
  function getOutfile(format, options, context) {
115
116
  const ext = getOutExtension(format, options);
116
117
  const candidate = (0, devkit_1.joinPathFragments)(context.target.options.outputPath, options.outputFileName);
117
118
  const { dir, name } = path.parse(candidate);
118
119
  return `${dir}/${name}${ext}`;
119
120
  }
120
- exports.getOutfile = getOutfile;
121
121
  function writeTmpEntryWithRequireOverrides(paths, outExtension, options, context) {
122
122
  const project = context.projectGraph?.nodes[context.projectName];
123
123
  // Write a temp main entry source that registers workspace libs.
@@ -218,7 +218,6 @@ function isFile(s) {
218
218
  require('${mainFile}');
219
219
  `;
220
220
  }
221
- exports.getRegisterFileContent = getRegisterFileContent;
222
221
  function getPrefixLength(pattern) {
223
222
  return pattern.substring(0, pattern.indexOf('*')).length;
224
223
  }
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getExtraDependencies = void 0;
3
+ exports.getExtraDependencies = getExtraDependencies;
4
4
  function getExtraDependencies(projectName, graph) {
5
5
  const deps = new Map();
6
6
  const visited = new Set(); // Track visited projects
@@ -35,4 +35,3 @@ function getExtraDependencies(projectName, graph) {
35
35
  }
36
36
  return Array.from(deps.values());
37
37
  }
38
- exports.getExtraDependencies = getExtraDependencies;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.normalizeOptions = void 0;
3
+ exports.normalizeOptions = normalizeOptions;
4
4
  const fs = require("fs");
5
5
  const path = require("path");
6
6
  const devkit_1 = require("@nx/devkit");
@@ -80,4 +80,3 @@ function normalizeOptions(options, context) {
80
80
  };
81
81
  }
82
82
  }
83
- exports.normalizeOptions = normalizeOptions;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.configurationGenerator = void 0;
3
+ exports.configurationGenerator = configurationGenerator;
4
4
  const devkit_1 = require("@nx/devkit");
5
5
  const get_import_path_1 = require("@nx/js/src/utils/get-import-path");
6
6
  const init_1 = require("../init/init");
@@ -16,7 +16,6 @@ async function configurationGenerator(tree, options) {
16
16
  await (0, devkit_1.formatFiles)(tree);
17
17
  return task;
18
18
  }
19
- exports.configurationGenerator = configurationGenerator;
20
19
  function checkForTargetConflicts(tree, options) {
21
20
  if (options.skipValidation)
22
21
  return;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.esbuildInitGenerator = void 0;
3
+ exports.esbuildInitGenerator = esbuildInitGenerator;
4
4
  const devkit_1 = require("@nx/devkit");
5
5
  const versions_1 = require("@nx/js/src/utils/versions");
6
6
  const versions_2 = require("../../utils/versions");
@@ -17,5 +17,4 @@ async function esbuildInitGenerator(tree, schema) {
17
17
  }
18
18
  return installTask;
19
19
  }
20
- exports.esbuildInitGenerator = esbuildInitGenerator;
21
20
  exports.default = esbuildInitGenerator;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = replacePackage;
3
4
  const devkit_1 = require("@nx/devkit");
4
5
  const replace_package_1 = require("@nx/devkit/src/utils/replace-package");
5
6
  async function replacePackage(tree) {
6
7
  await (0, replace_package_1.replaceNrwlPackageWithNxPackage)(tree, '@nrwl/esbuild', '@nx/esbuild');
7
8
  await (0, devkit_1.formatFiles)(tree);
8
9
  }
9
- exports.default = replacePackage;
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = update;
3
4
  /* eslint-disable @typescript-eslint/no-unused-vars */
4
5
  const devkit_1 = require("@nx/devkit");
5
6
  async function update(host) {
@@ -24,4 +25,3 @@ async function update(host) {
24
25
  });
25
26
  await (0, devkit_1.formatFiles)(host);
26
27
  }
27
- exports.default = update;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getClientEnvironment = void 0;
3
+ exports.getClientEnvironment = getClientEnvironment;
4
4
  function getClientEnvironment() {
5
5
  const nxPublicKeyRegex = /^NX_PUBLIC_/i;
6
6
  return Object.keys(process.env)
@@ -10,4 +10,3 @@ function getClientEnvironment() {
10
10
  return env;
11
11
  }, {});
12
12
  }
13
- exports.getClientEnvironment = getClientEnvironment;
package/src/utils/fs.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.deleteOutputDir = void 0;
3
+ exports.deleteOutputDir = deleteOutputDir;
4
4
  const path = require("path");
5
5
  const fs_extra_1 = require("fs-extra");
6
6
  /**
@@ -13,4 +13,3 @@ function deleteOutputDir(root, outputPath) {
13
13
  }
14
14
  (0, fs_extra_1.removeSync)(resolvedOutputPath);
15
15
  }
16
- exports.deleteOutputDir = deleteOutputDir;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getEntryPoints = void 0;
3
+ exports.getEntryPoints = getEntryPoints;
4
4
  const devkit_1 = require("@nx/devkit");
5
5
  const fs = require("fs");
6
6
  const path = require("path");
@@ -57,4 +57,3 @@ function getEntryPoints(projectName, context, options = {}) {
57
57
  findEntryPoints(projectName, options.initialTsConfigFileName);
58
58
  return Array.from(entryPoints);
59
59
  }
60
- exports.getEntryPoints = getEntryPoints;