@nx/js 16.6.0-beta.5 → 16.6.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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/js",
3
- "version": "16.6.0-beta.5",
3
+ "version": "16.6.0-beta.6",
4
4
  "private": false,
5
5
  "description": "The JS plugin for Nx contains executors and generators that provide the best experience for developing JavaScript and TypeScript projects. ",
6
6
  "repository": {
@@ -39,9 +39,9 @@
39
39
  "@babel/preset-env": "^7.22.9",
40
40
  "@babel/preset-typescript": "^7.22.5",
41
41
  "@babel/runtime": "^7.22.6",
42
- "@nrwl/js": "16.6.0-beta.5",
43
- "@nx/devkit": "16.6.0-beta.5",
44
- "@nx/workspace": "16.6.0-beta.5",
42
+ "@nrwl/js": "16.6.0-beta.6",
43
+ "@nx/devkit": "16.6.0-beta.6",
44
+ "@nx/workspace": "16.6.0-beta.6",
45
45
  "@phenomnomnominal/tsquery": "~5.0.1",
46
46
  "babel-plugin-const-enum": "^1.0.1",
47
47
  "babel-plugin-macros": "^2.8.0",
@@ -71,5 +71,5 @@
71
71
  "access": "public"
72
72
  },
73
73
  "types": "./src/index.d.ts",
74
- "gitHead": "aab868aa0c30949832fe2c4b9cb109c204442e39"
74
+ "gitHead": "9aad21dbfb2b659e488b6626f59df58ab23c0032"
75
75
  }
@@ -295,7 +295,7 @@ function normalizeOptions(tree, options, destinationDir) {
295
295
  * Now, the only way to get a non-buildble library is to set bundler to none.
296
296
  * By default, with nothing provided, libraries are buildable with `@nx/js:tsc`.
297
297
  */
298
- var _a, _b, _c;
298
+ var _a, _b, _c, _d;
299
299
  options.bundler = (_b = (_a = options.bundler) !== null && _a !== void 0 ? _a : options.compiler) !== null && _b !== void 0 ? _b : 'tsc';
300
300
  // ensure programmatic runs have an expected default
301
301
  if (!options.config) {
@@ -349,8 +349,10 @@ function normalizeOptions(tree, options, destinationDir) {
349
349
  const parsedTags = options.tags
350
350
  ? options.tags.split(',').map((s) => s.trim())
351
351
  : [];
352
- const importPath = options.importPath || (0, get_import_path_1.getImportPath)(tree, projectDirectory);
353
- (_c = options.minimal) !== null && _c !== void 0 ? _c : (options.minimal = false);
352
+ const importPath = options.rootProject
353
+ ? (_c = (0, devkit_1.readJson)(tree, 'package.json').name) !== null && _c !== void 0 ? _c : (0, get_import_path_1.getImportPath)(tree, 'core')
354
+ : options.importPath || (0, get_import_path_1.getImportPath)(tree, projectDirectory);
355
+ (_d = options.minimal) !== null && _d !== void 0 ? _d : (options.minimal = false);
354
356
  return Object.assign(Object.assign({}, options), { fileName, name: projectName, projectRoot,
355
357
  projectDirectory,
356
358
  parsedTags,