@nx/react 22.0.0-canary.20251015-f37c13b → 22.0.0-canary.20251018-6549d2a

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/react",
3
- "version": "22.0.0-canary.20251015-f37c13b",
3
+ "version": "22.0.0-canary.20251018-6549d2a",
4
4
  "private": false,
5
5
  "description": "The React plugin for Nx contains executors and generators for managing React applications and libraries within an Nx workspace. It provides:\n\n\n- Integration with libraries such as Jest, Vitest, Playwright, Cypress, and Storybook.\n\n- Generators for applications, libraries, components, hooks, and more.\n\n- Library build support for publishing packages to npm or other registries.\n\n- Utilities for automatic workspace refactoring.",
6
6
  "repository": {
@@ -38,22 +38,26 @@
38
38
  "minimatch": "9.0.3",
39
39
  "picocolors": "^1.1.0",
40
40
  "tslib": "^2.3.0",
41
- "@nx/devkit": "22.0.0-canary.20251015-f37c13b",
42
- "@nx/js": "22.0.0-canary.20251015-f37c13b",
43
- "@nx/eslint": "22.0.0-canary.20251015-f37c13b",
44
- "@nx/web": "22.0.0-canary.20251015-f37c13b",
45
- "@nx/vite": "22.0.0-canary.20251015-f37c13b",
46
- "@nx/module-federation": "22.0.0-canary.20251015-f37c13b",
47
- "@nx/rollup": "22.0.0-canary.20251015-f37c13b",
41
+ "@nx/devkit": "22.0.0-canary.20251018-6549d2a",
42
+ "@nx/js": "22.0.0-canary.20251018-6549d2a",
43
+ "@nx/eslint": "22.0.0-canary.20251018-6549d2a",
44
+ "@nx/web": "22.0.0-canary.20251018-6549d2a",
45
+ "@nx/module-federation": "22.0.0-canary.20251018-6549d2a",
46
+ "@nx/rollup": "22.0.0-canary.20251018-6549d2a",
48
47
  "express": "^4.21.2",
49
48
  "http-proxy-middleware": "^3.0.5",
50
49
  "semver": "^7.6.3"
51
50
  },
52
51
  "devDependencies": {
53
- "@nx/cypress": "22.0.0-canary.20251015-f37c13b",
54
- "@nx/playwright": "22.0.0-canary.20251015-f37c13b",
55
- "@nx/rsbuild": "22.0.0-canary.20251015-f37c13b",
56
- "nx": "22.0.0-canary.20251015-f37c13b"
52
+ "@nx/cypress": "22.0.0-canary.20251018-6549d2a",
53
+ "@nx/playwright": "22.0.0-canary.20251018-6549d2a",
54
+ "@nx/rsbuild": "22.0.0-canary.20251018-6549d2a",
55
+ "@nx/vite": "22.0.0-canary.20251018-6549d2a",
56
+ "@nx/webpack": "22.0.0-canary.20251018-6549d2a",
57
+ "nx": "22.0.0-canary.20251018-6549d2a"
58
+ },
59
+ "optionalDependencies": {
60
+ "@nx/vite": "22.0.0-canary.20251018-6549d2a"
57
61
  },
58
62
  "publishConfig": {
59
63
  "access": "public"
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../packages/react/plugins/storybook/index.ts"],"names":[],"mappings":"AAYA,OAAO,EACL,aAAa,EAId,MAAM,SAAS,CAAC;AA8CjB,eAAO,MAAM,IAAI,GAAI,SAAI,EAAE,YAAO,QAGhC,CAAC;AAqFH,eAAO,MAAM,OAAO,GAClB,wBAAwB,aAAkB,EAC1C,SAAS,GAAG,KACX,OAAO,CAAC,aAAa,CAsFvB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../packages/react/plugins/storybook/index.ts"],"names":[],"mappings":"AAYA,OAAO,EACL,aAAa,EAId,MAAM,SAAS,CAAC;AA8CjB,eAAO,MAAM,IAAI,GAAI,SAAI,EAAE,YAAO,QAGhC,CAAC;AAqFH,eAAO,MAAM,OAAO,GAClB,wBAAwB,aAAkB,EAC1C,SAAS,GAAG,KACX,OAAO,CAAC,aAAa,CAuFvB,CAAC"}
@@ -143,6 +143,7 @@ const webpack = async (storybookWebpackConfig = {}, options) => {
143
143
  const configure = (0, config_1.composePluginsSync)(withNx({ target: 'web', skipTypeChecking: true }), (0, with_react_1.withReact)());
144
144
  const finalConfig = configure(baseWebpackConfig, {
145
145
  options: builderOptions,
146
+ // TODO(JamesHenry): replace as any type assertion with as ExecutorContext once the nx repo is updated to use https://github.com/nrwl/nx/pull/33095
146
147
  context: { root: devkit_1.workspaceRoot }, // The context is not used here.
147
148
  });
148
149
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"module-federation-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/react/src/executors/module-federation-dev-server/module-federation-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAU,MAAM,YAAY,CAAC;AAarD,OAAO,EAAE,gCAAgC,EAAE,MAAM,UAAU,CAAC;AAE5D,wBAA+B,yBAAyB,CACtD,MAAM,EAAE,gCAAgC,EACxC,OAAO,EAAE,eAAe,GACvB,qBAAqB,CAAC;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAsG/D"}
1
+ {"version":3,"file":"module-federation-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/react/src/executors/module-federation-dev-server/module-federation-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAU,MAAM,YAAY,CAAC;AAarD,OAAO,EAAE,gCAAgC,EAAE,MAAM,UAAU,CAAC;AAE5D,wBAA+B,yBAAyB,CACtD,MAAM,EAAE,gCAAgC,EACxC,OAAO,EAAE,eAAe,GACvB,qBAAqB,CAAC;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAuG/D"}
@@ -22,7 +22,8 @@ async function* moduleFederationDevServer(schema, context) {
22
22
  cors: true,
23
23
  cacheSeconds: -1,
24
24
  }, context)
25
- : (0, dev_server_impl_1.default)(options, context);
25
+ : // TODO(JamesHenry): remove type assertion once the nx repo is updated to use https://github.com/nrwl/nx/pull/33095
26
+ (0, dev_server_impl_1.default)(options, context);
26
27
  const p = context.projectsConfigurations.projects[context.projectName];
27
28
  let pathToManifestFile = (0, path_1.join)(context.root, (0, ts_solution_setup_1.getProjectSourceRoot)(p), 'assets/module-federation.manifest.json');
28
29
  if (options.pathToManifestFile) {
@@ -1 +1 @@
1
- {"version":3,"file":"module-federation-ssr-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/react/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAU,MAAM,YAAY,CAAC;AAYrD,OAAO,EAAE,mCAAmC,EAAE,MAAM,UAAU,CAAC;AAE/D,wBAA+B,4BAA4B,CACzD,mBAAmB,EAAE,mCAAmC,EACxD,OAAO,EAAE,eAAe,iCA2GzB"}
1
+ {"version":3,"file":"module-federation-ssr-dev-server.impl.d.ts","sourceRoot":"","sources":["../../../../../../packages/react/src/executors/module-federation-ssr-dev-server/module-federation-ssr-dev-server.impl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAU,MAAM,YAAY,CAAC;AAYrD,OAAO,EAAE,mCAAmC,EAAE,MAAM,UAAU,CAAC;AAE/D,wBAA+B,4BAA4B,CACzD,mBAAmB,EAAE,mCAAmC,EACxD,OAAO,EAAE,eAAe,iCA4GzB"}
@@ -12,6 +12,7 @@ const path_1 = require("path");
12
12
  const lib_1 = require("./lib");
13
13
  async function* moduleFederationSsrDevServer(ssrDevServerOptions, context) {
14
14
  const options = (0, lib_1.normalizeOptions)(ssrDevServerOptions);
15
+ // TODO(JamesHenry): remove type assertion once the nx repo is updated to use https://github.com/nrwl/nx/pull/33095
15
16
  let iter = (0, ssr_dev_server_impl_1.default)(options, context);
16
17
  const projectConfig = context.projectsConfigurations.projects[context.projectName];
17
18
  let pathToManifestFile = (0, path_1.join)(context.root, (0, ts_solution_setup_1.getProjectSourceRoot)(projectConfig), 'assets/module-federation.manifest.json');
@@ -1 +1 @@
1
- {"version":3,"file":"version-utils.d.ts","sourceRoot":"","sources":["../../../../../packages/react/src/utils/version-utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,EAAqC,MAAM,YAAY,CAAC;AAiB1E,KAAK,yBAAyB,GAAG;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,iBAAiB,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,wBAAsB,qCAAqC,CACzD,IAAI,EAAE,IAAI,GACT,OAAO,CAAC,yBAAyB,CAAC,CAoBpC;AAED,wBAAsB,SAAS,CAAC,IAAI,EAAE,IAAI,oBAMzC;AAED,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAc3D;AAED,wBAAsB,iCAAiC,oBAOtD"}
1
+ {"version":3,"file":"version-utils.d.ts","sourceRoot":"","sources":["../../../../../packages/react/src/utils/version-utils.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,IAAI,EAGV,MAAM,YAAY,CAAC;AAiBpB,KAAK,yBAAyB,GAAG;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,iBAAiB,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,wBAAsB,qCAAqC,CACzD,IAAI,EAAE,IAAI,GACT,OAAO,CAAC,yBAAyB,CAAC,CAoBpC;AAED,wBAAsB,SAAS,CAAC,IAAI,EAAE,IAAI,oBAMzC;AAED,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAe3D;AAED,wBAAsB,iCAAiC,oBAOtD"}
@@ -37,8 +37,7 @@ async function isReact18(tree) {
37
37
  return (0, semver_1.major)(installedReactVersion) === 18;
38
38
  }
39
39
  function getInstalledReactVersion(tree) {
40
- const pkgJson = (0, devkit_1.readJson)(tree, 'package.json');
41
- const installedReactVersion = pkgJson.dependencies && pkgJson.dependencies['react'];
40
+ const installedReactVersion = (0, devkit_1.getDependencyVersionFromPackageJson)(tree, 'react');
42
41
  if (!installedReactVersion ||
43
42
  installedReactVersion === 'latest' ||
44
43
  installedReactVersion === 'next') {