@nx/webpack 23.0.0-beta.22 → 23.0.0-beta.24

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.
Files changed (234) hide show
  1. package/{app-plugin.d.ts → dist/app-plugin.d.ts} +0 -1
  2. package/{index.d.ts → dist/index.d.ts} +0 -1
  3. package/dist/internal.d.ts +8 -0
  4. package/dist/internal.js +26 -0
  5. package/{plugin.d.ts → dist/plugin.d.ts} +0 -1
  6. package/{src → dist/src}/executors/dev-server/dev-server.impl.d.ts +0 -1
  7. package/{src → dist/src}/executors/dev-server/dev-server.impl.js +4 -4
  8. package/{src → dist/src}/executors/dev-server/lib/get-dev-server-config.d.ts +0 -1
  9. package/{src → dist/src}/executors/dev-server/lib/serve-path.d.ts +0 -1
  10. package/{src → dist/src}/executors/ssr-dev-server/lib/wait-until-server-is-listening.d.ts +0 -1
  11. package/{src → dist/src}/executors/ssr-dev-server/ssr-dev-server.impl.d.ts +0 -1
  12. package/{src → dist/src}/executors/webpack/lib/normalize-options.d.ts +0 -1
  13. package/{src → dist/src}/executors/webpack/lib/run-webpack.d.ts +1 -2
  14. package/{src → dist/src}/executors/webpack/lib/run-webpack.js +3 -3
  15. package/{src → dist/src}/executors/webpack/webpack.impl.d.ts +0 -1
  16. package/{src → dist/src}/generators/configuration/configuration.d.ts +0 -1
  17. package/{src → dist/src}/generators/configuration/configuration.js +2 -0
  18. package/{src → dist/src}/generators/convert-config-to-webpack-plugin/convert-config-to-webpack-plugin.d.ts +0 -1
  19. package/{src → dist/src}/generators/convert-config-to-webpack-plugin/convert-config-to-webpack-plugin.js +2 -0
  20. package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/extract-webpack-options.d.ts +0 -1
  21. package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/normalize-path-options.d.ts +0 -1
  22. package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/utils.d.ts +0 -1
  23. package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/validate-project.d.ts +0 -1
  24. package/{src → dist/src}/generators/convert-to-inferred/convert-to-inferred.d.ts +0 -1
  25. package/{src → dist/src}/generators/convert-to-inferred/convert-to-inferred.js +1 -0
  26. package/{src → dist/src}/generators/convert-to-inferred/utils/ast.d.ts +0 -1
  27. package/{src → dist/src}/generators/convert-to-inferred/utils/build-post-target-transformer.d.ts +0 -1
  28. package/{src → dist/src}/generators/convert-to-inferred/utils/index.d.ts +0 -1
  29. package/{src → dist/src}/generators/convert-to-inferred/utils/serve-post-target-transformer.d.ts +0 -1
  30. package/{src → dist/src}/generators/convert-to-inferred/utils/types.d.ts +0 -1
  31. package/{src → dist/src}/generators/init/init.d.ts +0 -1
  32. package/{src → dist/src}/generators/init/init.js +8 -1
  33. package/{src → dist/src}/generators/init/schema.json +1 -1
  34. package/{src → dist/src}/migrations/update-21-0-0/remove-isolated-config.d.ts +0 -1
  35. package/{src → dist/src}/migrations/update-22-0-0/remove-deprecated-options.d.ts +0 -1
  36. package/dist/src/migrations/update-23-0-0/migrate-create-nodes-v2-to-create-nodes.d.ts +9 -0
  37. package/dist/src/migrations/update-23-0-0/migrate-create-nodes-v2-to-create-nodes.js +134 -0
  38. package/dist/src/migrations/update-23-0-0/migrate-create-nodes-v2-to-create-nodes.md +25 -0
  39. package/{src → dist/src}/migrations/update-23-0-0/remove-nx-tsconfig-paths-webpack-plugin-import.d.ts +0 -1
  40. package/dist/src/migrations/update-23-0-0/rewrite-internal-subpath-imports.d.ts +3 -0
  41. package/dist/src/migrations/update-23-0-0/rewrite-internal-subpath-imports.js +225 -0
  42. package/{src → dist/src}/plugins/generate-package-json-plugin.d.ts +0 -1
  43. package/{src → dist/src}/plugins/nx-typescript-webpack-plugin/nx-tsconfig-paths-webpack-plugin.d.ts +0 -1
  44. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/apply-base-config.d.ts +0 -1
  45. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/apply-web-config.d.ts +0 -1
  46. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/compiler-loaders.d.ts +0 -1
  47. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/get-terser-ecma-version.d.ts +0 -1
  48. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/instantiate-script-plugins.d.ts +0 -1
  49. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/normalize-options.d.ts +0 -1
  50. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/stylesheet-loaders.d.ts +0 -1
  51. package/{src → dist/src}/plugins/nx-webpack-plugin/lib/utils.d.ts +0 -1
  52. package/{src → dist/src}/plugins/nx-webpack-plugin/nx-app-webpack-plugin-options.d.ts +0 -1
  53. package/{src → dist/src}/plugins/nx-webpack-plugin/nx-app-webpack-plugin.d.ts +0 -1
  54. package/{src → dist/src}/plugins/plugin.d.ts +3 -4
  55. package/{src → dist/src}/plugins/plugin.js +3 -3
  56. package/{src → dist/src}/plugins/stats-json-plugin.d.ts +0 -1
  57. package/{src → dist/src}/plugins/use-legacy-nx-plugin/use-legacy-nx-plugin.d.ts +0 -1
  58. package/{src → dist/src}/plugins/webpack-nx-build-coordination-plugin.d.ts +0 -1
  59. package/{src → dist/src}/plugins/write-index-html-plugin.d.ts +0 -1
  60. package/{src → dist/src}/utils/config.d.ts +12 -1
  61. package/{src → dist/src}/utils/config.js +15 -0
  62. package/{src → dist/src}/utils/create-copy-plugin.d.ts +0 -1
  63. package/{src → dist/src}/utils/deprecation.d.ts +3 -1
  64. package/{src → dist/src}/utils/deprecation.js +31 -1
  65. package/{src → dist/src}/utils/e2e-web-server-info-utils.d.ts +0 -1
  66. package/{src → dist/src}/utils/ensure-dependencies.d.ts +0 -1
  67. package/{src → dist/src}/utils/ensure-dependencies.js +1 -1
  68. package/{src → dist/src}/utils/fs.d.ts +0 -1
  69. package/{src → dist/src}/utils/get-client-environment.d.ts +0 -1
  70. package/{src → dist/src}/utils/get-css-module-local-ident.d.ts +0 -1
  71. package/{src → dist/src}/utils/has-plugin.d.ts +0 -1
  72. package/{src → dist/src}/utils/hash-format.d.ts +0 -1
  73. package/{src → dist/src}/utils/models.d.ts +0 -1
  74. package/{src → dist/src}/utils/run-webpack.d.ts +0 -1
  75. package/dist/src/utils/versions.d.ts +12 -0
  76. package/dist/src/utils/versions.js +24 -0
  77. package/dist/src/utils/web-babel-loader.d.ts +1 -0
  78. package/{src → dist/src}/utils/web-babel-loader.js +2 -0
  79. package/{src → dist/src}/utils/webpack/interpolate-env-variables-to-index.d.ts +0 -1
  80. package/{src → dist/src}/utils/webpack/normalize-entry.d.ts +0 -1
  81. package/{src → dist/src}/utils/webpack/package-chunk-sort.d.ts +0 -1
  82. package/{src → dist/src}/utils/webpack/plugins/postcss-cli-resources.d.ts +0 -1
  83. package/{src → dist/src}/utils/webpack/plugins/scripts-webpack-plugin.d.ts +0 -1
  84. package/{src → dist/src}/utils/webpack/read-webpack-options.d.ts +0 -1
  85. package/{src → dist/src}/utils/webpack/resolve-user-defined-webpack-config.d.ts +0 -1
  86. package/{src → dist/src}/utils/with-nx.d.ts +4 -1
  87. package/{src → dist/src}/utils/with-nx.js +6 -0
  88. package/{src → dist/src}/utils/with-web.d.ts +4 -1
  89. package/{src → dist/src}/utils/with-web.js +6 -0
  90. package/{tsconfig-paths-plugin.d.ts → dist/tsconfig-paths-plugin.d.ts} +0 -1
  91. package/executors.json +6 -6
  92. package/generators.json +8 -8
  93. package/migrations.json +36 -5
  94. package/package.json +78 -9
  95. package/app-plugin.d.ts.map +0 -1
  96. package/index.d.ts.map +0 -1
  97. package/plugin.d.ts.map +0 -1
  98. package/src/executors/dev-server/dev-server.impl.d.ts.map +0 -1
  99. package/src/executors/dev-server/lib/get-dev-server-config.d.ts.map +0 -1
  100. package/src/executors/dev-server/lib/serve-path.d.ts.map +0 -1
  101. package/src/executors/ssr-dev-server/lib/wait-until-server-is-listening.d.ts.map +0 -1
  102. package/src/executors/ssr-dev-server/ssr-dev-server.impl.d.ts.map +0 -1
  103. package/src/executors/webpack/lib/normalize-options.d.ts.map +0 -1
  104. package/src/executors/webpack/lib/run-webpack.d.ts.map +0 -1
  105. package/src/executors/webpack/webpack.impl.d.ts.map +0 -1
  106. package/src/generators/configuration/configuration.d.ts.map +0 -1
  107. package/src/generators/convert-config-to-webpack-plugin/convert-config-to-webpack-plugin.d.ts.map +0 -1
  108. package/src/generators/convert-config-to-webpack-plugin/lib/extract-webpack-options.d.ts.map +0 -1
  109. package/src/generators/convert-config-to-webpack-plugin/lib/normalize-path-options.d.ts.map +0 -1
  110. package/src/generators/convert-config-to-webpack-plugin/lib/utils.d.ts.map +0 -1
  111. package/src/generators/convert-config-to-webpack-plugin/lib/validate-project.d.ts.map +0 -1
  112. package/src/generators/convert-to-inferred/convert-to-inferred.d.ts.map +0 -1
  113. package/src/generators/convert-to-inferred/utils/ast.d.ts.map +0 -1
  114. package/src/generators/convert-to-inferred/utils/build-post-target-transformer.d.ts.map +0 -1
  115. package/src/generators/convert-to-inferred/utils/index.d.ts.map +0 -1
  116. package/src/generators/convert-to-inferred/utils/serve-post-target-transformer.d.ts.map +0 -1
  117. package/src/generators/convert-to-inferred/utils/types.d.ts.map +0 -1
  118. package/src/generators/init/init.d.ts.map +0 -1
  119. package/src/migrations/update-21-0-0/remove-isolated-config.d.ts.map +0 -1
  120. package/src/migrations/update-22-0-0/remove-deprecated-options.d.ts.map +0 -1
  121. package/src/migrations/update-23-0-0/remove-nx-tsconfig-paths-webpack-plugin-import.d.ts.map +0 -1
  122. package/src/plugins/generate-package-json-plugin.d.ts.map +0 -1
  123. package/src/plugins/nx-typescript-webpack-plugin/nx-tsconfig-paths-webpack-plugin.d.ts.map +0 -1
  124. package/src/plugins/nx-webpack-plugin/lib/apply-base-config.d.ts.map +0 -1
  125. package/src/plugins/nx-webpack-plugin/lib/apply-web-config.d.ts.map +0 -1
  126. package/src/plugins/nx-webpack-plugin/lib/compiler-loaders.d.ts.map +0 -1
  127. package/src/plugins/nx-webpack-plugin/lib/get-terser-ecma-version.d.ts.map +0 -1
  128. package/src/plugins/nx-webpack-plugin/lib/instantiate-script-plugins.d.ts.map +0 -1
  129. package/src/plugins/nx-webpack-plugin/lib/normalize-options.d.ts.map +0 -1
  130. package/src/plugins/nx-webpack-plugin/lib/stylesheet-loaders.d.ts.map +0 -1
  131. package/src/plugins/nx-webpack-plugin/lib/utils.d.ts.map +0 -1
  132. package/src/plugins/nx-webpack-plugin/nx-app-webpack-plugin-options.d.ts.map +0 -1
  133. package/src/plugins/nx-webpack-plugin/nx-app-webpack-plugin.d.ts.map +0 -1
  134. package/src/plugins/plugin.d.ts.map +0 -1
  135. package/src/plugins/stats-json-plugin.d.ts.map +0 -1
  136. package/src/plugins/use-legacy-nx-plugin/use-legacy-nx-plugin.d.ts.map +0 -1
  137. package/src/plugins/webpack-nx-build-coordination-plugin.d.ts.map +0 -1
  138. package/src/plugins/write-index-html-plugin.d.ts.map +0 -1
  139. package/src/utils/config.d.ts.map +0 -1
  140. package/src/utils/create-copy-plugin.d.ts.map +0 -1
  141. package/src/utils/deprecation.d.ts.map +0 -1
  142. package/src/utils/e2e-web-server-info-utils.d.ts.map +0 -1
  143. package/src/utils/ensure-dependencies.d.ts.map +0 -1
  144. package/src/utils/fs.d.ts.map +0 -1
  145. package/src/utils/get-client-environment.d.ts.map +0 -1
  146. package/src/utils/get-css-module-local-ident.d.ts.map +0 -1
  147. package/src/utils/has-plugin.d.ts.map +0 -1
  148. package/src/utils/hash-format.d.ts.map +0 -1
  149. package/src/utils/models.d.ts.map +0 -1
  150. package/src/utils/run-webpack.d.ts.map +0 -1
  151. package/src/utils/versions.d.ts +0 -8
  152. package/src/utils/versions.d.ts.map +0 -1
  153. package/src/utils/versions.js +0 -11
  154. package/src/utils/web-babel-loader.d.ts +0 -1
  155. package/src/utils/web-babel-loader.d.ts.map +0 -1
  156. package/src/utils/webpack/interpolate-env-variables-to-index.d.ts.map +0 -1
  157. package/src/utils/webpack/normalize-entry.d.ts.map +0 -1
  158. package/src/utils/webpack/package-chunk-sort.d.ts.map +0 -1
  159. package/src/utils/webpack/plugins/postcss-cli-resources.d.ts.map +0 -1
  160. package/src/utils/webpack/plugins/scripts-webpack-plugin.d.ts.map +0 -1
  161. package/src/utils/webpack/read-webpack-options.d.ts.map +0 -1
  162. package/src/utils/webpack/resolve-user-defined-webpack-config.d.ts.map +0 -1
  163. package/src/utils/with-nx.d.ts.map +0 -1
  164. package/src/utils/with-web.d.ts.map +0 -1
  165. package/tsconfig-paths-plugin.d.ts.map +0 -1
  166. /package/{LICENSE → dist/LICENSE} +0 -0
  167. /package/{app-plugin.js → dist/app-plugin.js} +0 -0
  168. /package/{index.js → dist/index.js} +0 -0
  169. /package/{plugin.js → dist/plugin.js} +0 -0
  170. /package/{src → dist/src}/executors/dev-server/lib/get-dev-server-config.js +0 -0
  171. /package/{src → dist/src}/executors/dev-server/lib/serve-path.js +0 -0
  172. /package/{src → dist/src}/executors/dev-server/schema.d.ts +0 -0
  173. /package/{src → dist/src}/executors/dev-server/schema.json +0 -0
  174. /package/{src → dist/src}/executors/ssr-dev-server/lib/wait-until-server-is-listening.js +0 -0
  175. /package/{src → dist/src}/executors/ssr-dev-server/schema.d.ts +0 -0
  176. /package/{src → dist/src}/executors/ssr-dev-server/schema.json +0 -0
  177. /package/{src → dist/src}/executors/ssr-dev-server/ssr-dev-server.impl.js +0 -0
  178. /package/{src → dist/src}/executors/webpack/lib/normalize-options.js +0 -0
  179. /package/{src → dist/src}/executors/webpack/schema.d.ts +0 -0
  180. /package/{src → dist/src}/executors/webpack/schema.json +0 -0
  181. /package/{src → dist/src}/executors/webpack/webpack.impl.js +0 -0
  182. /package/{src → dist/src}/generators/configuration/schema.d.ts +0 -0
  183. /package/{src → dist/src}/generators/configuration/schema.json +0 -0
  184. /package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/extract-webpack-options.js +0 -0
  185. /package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/normalize-path-options.js +0 -0
  186. /package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/utils.js +0 -0
  187. /package/{src → dist/src}/generators/convert-config-to-webpack-plugin/lib/validate-project.js +0 -0
  188. /package/{src → dist/src}/generators/convert-config-to-webpack-plugin/schema.json +0 -0
  189. /package/{src → dist/src}/generators/convert-to-inferred/schema.json +0 -0
  190. /package/{src → dist/src}/generators/convert-to-inferred/utils/ast.js +0 -0
  191. /package/{src → dist/src}/generators/convert-to-inferred/utils/build-post-target-transformer.js +0 -0
  192. /package/{src → dist/src}/generators/convert-to-inferred/utils/index.js +0 -0
  193. /package/{src → dist/src}/generators/convert-to-inferred/utils/serve-post-target-transformer.js +0 -0
  194. /package/{src → dist/src}/generators/convert-to-inferred/utils/types.js +0 -0
  195. /package/{src → dist/src}/generators/init/schema.d.ts +0 -0
  196. /package/{src → dist/src}/migrations/update-21-0-0/remove-isolated-config.js +0 -0
  197. /package/{src → dist/src}/migrations/update-21-0-0/remove-isolated-config.md +0 -0
  198. /package/{src → dist/src}/migrations/update-22-0-0/remove-deprecated-options.js +0 -0
  199. /package/{src → dist/src}/migrations/update-23-0-0/remove-nx-tsconfig-paths-webpack-plugin-import.js +0 -0
  200. /package/{src → dist/src}/migrations/update-23-0-0/remove-nx-tsconfig-paths-webpack-plugin-import.md +0 -0
  201. /package/{src → dist/src}/plugins/generate-package-json-plugin.js +0 -0
  202. /package/{src → dist/src}/plugins/nx-typescript-webpack-plugin/nx-tsconfig-paths-webpack-plugin.js +0 -0
  203. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/apply-base-config.js +0 -0
  204. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/apply-web-config.js +0 -0
  205. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/compiler-loaders.js +0 -0
  206. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/get-terser-ecma-version.js +0 -0
  207. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/instantiate-script-plugins.js +0 -0
  208. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/normalize-options.js +0 -0
  209. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/stylesheet-loaders.js +0 -0
  210. /package/{src → dist/src}/plugins/nx-webpack-plugin/lib/utils.js +0 -0
  211. /package/{src → dist/src}/plugins/nx-webpack-plugin/nx-app-webpack-plugin-options.js +0 -0
  212. /package/{src → dist/src}/plugins/nx-webpack-plugin/nx-app-webpack-plugin.js +0 -0
  213. /package/{src → dist/src}/plugins/stats-json-plugin.js +0 -0
  214. /package/{src → dist/src}/plugins/use-legacy-nx-plugin/use-legacy-nx-plugin.js +0 -0
  215. /package/{src → dist/src}/plugins/webpack-nx-build-coordination-plugin.js +0 -0
  216. /package/{src → dist/src}/plugins/write-index-html-plugin.js +0 -0
  217. /package/{src → dist/src}/utils/create-copy-plugin.js +0 -0
  218. /package/{src → dist/src}/utils/e2e-web-server-info-utils.js +0 -0
  219. /package/{src → dist/src}/utils/fs.js +0 -0
  220. /package/{src → dist/src}/utils/get-client-environment.js +0 -0
  221. /package/{src → dist/src}/utils/get-css-module-local-ident.js +0 -0
  222. /package/{src → dist/src}/utils/has-plugin.js +0 -0
  223. /package/{src → dist/src}/utils/hash-format.js +0 -0
  224. /package/{src → dist/src}/utils/models.js +0 -0
  225. /package/{src → dist/src}/utils/run-webpack.js +0 -0
  226. /package/{src → dist/src}/utils/webpack/deprecated-less-loader.js +0 -0
  227. /package/{src → dist/src}/utils/webpack/interpolate-env-variables-to-index.js +0 -0
  228. /package/{src → dist/src}/utils/webpack/normalize-entry.js +0 -0
  229. /package/{src → dist/src}/utils/webpack/package-chunk-sort.js +0 -0
  230. /package/{src → dist/src}/utils/webpack/plugins/postcss-cli-resources.js +0 -0
  231. /package/{src → dist/src}/utils/webpack/plugins/scripts-webpack-plugin.js +0 -0
  232. /package/{src → dist/src}/utils/webpack/read-webpack-options.js +0 -0
  233. /package/{src → dist/src}/utils/webpack/resolve-user-defined-webpack-config.js +0 -0
  234. /package/{tsconfig-paths-plugin.js → dist/tsconfig-paths-plugin.js} +0 -0
@@ -1,3 +1,2 @@
1
1
  export { NxAppWebpackPlugin } from './src/plugins/nx-webpack-plugin/nx-app-webpack-plugin';
2
2
  export type { NxAppWebpackPluginOptions } from './src/plugins/nx-webpack-plugin/nx-app-webpack-plugin-options';
3
- //# sourceMappingURL=app-plugin.d.ts.map
@@ -19,4 +19,3 @@ export * from './src/utils/get-css-module-local-ident';
19
19
  export * from './src/utils/with-nx';
20
20
  export * from './src/utils/with-web';
21
21
  export * from './src/utils/e2e-web-server-info-utils';
22
- //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,8 @@
1
+ export { findUp, findAllNodeModules, deleteOutputDir } from './src/utils/fs';
2
+ export { ensureDependencies } from './src/utils/ensure-dependencies';
3
+ export type { EnsureDependenciesOptions } from './src/utils/ensure-dependencies';
4
+ export { resolveUserDefinedWebpackConfig } from './src/utils/webpack/resolve-user-defined-webpack-config';
5
+ export { suppressWebpackComposeHelperWarnings } from './src/utils/deprecation';
6
+ export { WebpackNxBuildCoordinationPlugin } from './src/plugins/webpack-nx-build-coordination-plugin';
7
+ export type { WebSsrDevServerOptions } from './src/executors/ssr-dev-server/schema';
8
+ export { default as ssrDevServerExecutor } from './src/executors/ssr-dev-server/ssr-dev-server.impl';
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ssrDevServerExecutor = exports.WebpackNxBuildCoordinationPlugin = exports.suppressWebpackComposeHelperWarnings = exports.resolveUserDefinedWebpackConfig = exports.ensureDependencies = exports.deleteOutputDir = exports.findAllNodeModules = exports.findUp = void 0;
4
+ const tslib_1 = require("tslib");
5
+ // Curated internal API surface for other first-party Nx plugins (e.g. @nx/react,
6
+ // @nx/angular, @nx/web, @nx/node, @nx/next, @nx/react-native). Prefer this over
7
+ // deep `@nx/webpack/src/*` imports — those are not part of the public API.
8
+ //
9
+ // Only truly-internal symbols belong here. Anything exported from @nx/webpack's
10
+ // public entry (composePluginsSync, withNx, withWeb, normalizeOptions,
11
+ // normalizePluginPath, devServerExecutor, NormalizedWebpackExecutorOptions, …)
12
+ // must be imported from '@nx/webpack', not from here.
13
+ var fs_1 = require("./src/utils/fs");
14
+ Object.defineProperty(exports, "findUp", { enumerable: true, get: function () { return fs_1.findUp; } });
15
+ Object.defineProperty(exports, "findAllNodeModules", { enumerable: true, get: function () { return fs_1.findAllNodeModules; } });
16
+ Object.defineProperty(exports, "deleteOutputDir", { enumerable: true, get: function () { return fs_1.deleteOutputDir; } });
17
+ var ensure_dependencies_1 = require("./src/utils/ensure-dependencies");
18
+ Object.defineProperty(exports, "ensureDependencies", { enumerable: true, get: function () { return ensure_dependencies_1.ensureDependencies; } });
19
+ var resolve_user_defined_webpack_config_1 = require("./src/utils/webpack/resolve-user-defined-webpack-config");
20
+ Object.defineProperty(exports, "resolveUserDefinedWebpackConfig", { enumerable: true, get: function () { return resolve_user_defined_webpack_config_1.resolveUserDefinedWebpackConfig; } });
21
+ var deprecation_1 = require("./src/utils/deprecation");
22
+ Object.defineProperty(exports, "suppressWebpackComposeHelperWarnings", { enumerable: true, get: function () { return deprecation_1.suppressWebpackComposeHelperWarnings; } });
23
+ var webpack_nx_build_coordination_plugin_1 = require("./src/plugins/webpack-nx-build-coordination-plugin");
24
+ Object.defineProperty(exports, "WebpackNxBuildCoordinationPlugin", { enumerable: true, get: function () { return webpack_nx_build_coordination_plugin_1.WebpackNxBuildCoordinationPlugin; } });
25
+ var ssr_dev_server_impl_1 = require("./src/executors/ssr-dev-server/ssr-dev-server.impl");
26
+ Object.defineProperty(exports, "ssrDevServerExecutor", { enumerable: true, get: function () { return tslib_1.__importDefault(ssr_dev_server_impl_1).default; } });
@@ -1,2 +1 @@
1
1
  export { createNodes, createNodesV2, type WebpackPluginOptions, } from './src/plugins/plugin';
2
- //# sourceMappingURL=plugin.d.ts.map
@@ -5,4 +5,3 @@ export declare function devServerExecutor(serveOptions: WebDevServerOptions, con
5
5
  success: boolean;
6
6
  }, any, any>;
7
7
  export default devServerExecutor;
8
- //# sourceMappingURL=dev-server.impl.d.ts.map
@@ -1,12 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.devServerExecutor = devServerExecutor;
4
- const tslib_1 = require("tslib");
5
4
  const internal_1 = require("@nx/devkit/internal");
6
- const webpack_1 = tslib_1.__importDefault(require("webpack"));
7
5
  const devkit_1 = require("@nx/devkit");
8
6
  const operators_1 = require("rxjs/operators");
9
- const webpack_dev_server_1 = tslib_1.__importDefault(require("webpack-dev-server"));
10
7
  const get_dev_server_config_1 = require("./lib/get-dev-server-config");
11
8
  const internal_2 = require("@nx/js/internal");
12
9
  const run_webpack_1 = require("../../utils/run-webpack");
@@ -63,7 +60,10 @@ async function* devServerExecutor(serveOptions, context) {
63
60
  config.devServer ??= devServer;
64
61
  }
65
62
  }
66
- return yield* (0, internal_1.eachValueFrom)((0, run_webpack_1.runWebpackDevServer)(config, webpack_1.default, webpack_dev_server_1.default).pipe((0, operators_1.tap)(({ stats }) => {
63
+ // Lazy-loaded: optional peers absent during project-graph discovery.
64
+ const webpack = require('webpack');
65
+ const WebpackDevServer = require('webpack-dev-server');
66
+ return yield* (0, internal_1.eachValueFrom)((0, run_webpack_1.runWebpackDevServer)(config, webpack, WebpackDevServer).pipe((0, operators_1.tap)(({ stats }) => {
67
67
  console.info(stats.toString(config.stats));
68
68
  }), (0, operators_1.map)(({ baseUrl, stats }) => {
69
69
  return {
@@ -2,4 +2,3 @@ import type { Configuration as WebpackDevServerConfiguration } from 'webpack-dev
2
2
  import { WebDevServerOptions } from '../schema';
3
3
  import { NormalizedWebpackExecutorOptions } from '../../webpack/schema';
4
4
  export declare function getDevServerOptions(root: string, serveOptions: WebDevServerOptions, buildOptions: NormalizedWebpackExecutorOptions): WebpackDevServerConfiguration;
5
- //# sourceMappingURL=get-dev-server-config.d.ts.map
@@ -1,4 +1,3 @@
1
1
  import type { NormalizedWebpackExecutorOptions } from '../../webpack/schema';
2
2
  export declare function buildServePath(browserOptions: NormalizedWebpackExecutorOptions): string;
3
3
  export declare function _findDefaultServePath(baseHref?: string, deployUrl?: string): string | null;
4
- //# sourceMappingURL=serve-path.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare function waitUntilServerIsListening(port: number): Promise<void>;
2
- //# sourceMappingURL=wait-until-server-is-listening.d.ts.map
@@ -6,4 +6,3 @@ export declare function ssrDevServerExecutor(options: WebSsrDevServerOptions, co
6
6
  options: TargetOptions;
7
7
  }, void, unknown>;
8
8
  export default ssrDevServerExecutor;
9
- //# sourceMappingURL=ssr-dev-server.impl.d.ts.map
@@ -1,4 +1,3 @@
1
1
  import type { NormalizedWebpackExecutorOptions, WebpackExecutorOptions } from '../schema';
2
2
  export declare function normalizeOptions(options: WebpackExecutorOptions, root: string, projectRoot: string, sourceRoot: string): NormalizedWebpackExecutorOptions;
3
3
  export declare function normalizePluginPath(pluginPath: void | string, root: string): string;
4
- //# sourceMappingURL=normalize-options.d.ts.map
@@ -1,4 +1,3 @@
1
- import webpack from 'webpack';
1
+ import type webpack from 'webpack';
2
2
  import { Observable } from 'rxjs';
3
3
  export declare function runWebpack(config: webpack.Configuration): Observable<webpack.Stats>;
4
- //# sourceMappingURL=run-webpack.d.ts.map
@@ -1,16 +1,16 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.runWebpack = runWebpack;
4
- const tslib_1 = require("tslib");
5
- const webpack_1 = tslib_1.__importDefault(require("webpack"));
6
4
  const rxjs_1 = require("rxjs");
7
5
  // TODO(jack): move to dev-server executor
8
6
  function runWebpack(config) {
7
+ // Lazy-loaded: `webpack` is an optional peer, absent during project-graph discovery.
8
+ const webpackImpl = require('webpack');
9
9
  return new rxjs_1.Observable((subscriber) => {
10
10
  // Passing `watch` option here will result in a warning due to missing callback.
11
11
  // We manually call `.watch` or `.run` later so this option isn't needed here.
12
12
  const { watch, ...normalizedConfig } = config;
13
- const webpackCompiler = (0, webpack_1.default)(normalizedConfig);
13
+ const webpackCompiler = webpackImpl(normalizedConfig);
14
14
  const callback = (err, stats) => {
15
15
  if (err) {
16
16
  subscriber.error(err);
@@ -11,4 +11,3 @@ export type WebpackExecutorEvent = {
11
11
  };
12
12
  export declare function webpackExecutor(_options: WebpackExecutorOptions, context: ExecutorContext): AsyncGenerator<WebpackExecutorEvent, WebpackExecutorEvent, undefined>;
13
13
  export default webpackExecutor;
14
- //# sourceMappingURL=webpack.impl.d.ts.map
@@ -3,4 +3,3 @@ import { ConfigurationGeneratorSchema } from './schema';
3
3
  export declare function configurationGenerator(tree: Tree, options: ConfigurationGeneratorSchema): Promise<GeneratorCallback>;
4
4
  export declare function configurationGeneratorInternal(tree: Tree, options: ConfigurationGeneratorSchema): Promise<GeneratorCallback>;
5
5
  export default configurationGenerator;
6
- //# sourceMappingURL=configuration.d.ts.map
@@ -9,10 +9,12 @@ const has_plugin_1 = require("../../utils/has-plugin");
9
9
  const deprecation_1 = require("../../utils/deprecation");
10
10
  const internal_2 = require("@nx/js/internal");
11
11
  const ensure_dependencies_1 = require("../../utils/ensure-dependencies");
12
+ const versions_1 = require("../../utils/versions");
12
13
  function configurationGenerator(tree, options) {
13
14
  return configurationGeneratorInternal(tree, { addPlugin: false, ...options });
14
15
  }
15
16
  async function configurationGeneratorInternal(tree, options) {
17
+ (0, versions_1.assertSupportedWebpackVersion)(tree);
16
18
  const tasks = [];
17
19
  const nxJson = (0, devkit_1.readNxJson)(tree);
18
20
  const addPluginDefault = process.env.NX_ADD_PLUGINS !== 'false' &&
@@ -5,4 +5,3 @@ interface Schema {
5
5
  }
6
6
  export declare function convertConfigToWebpackPluginGenerator(tree: Tree, options: Schema): Promise<void>;
7
7
  export default convertConfigToWebpackPluginGenerator;
8
- //# sourceMappingURL=convert-config-to-webpack-plugin.d.ts.map
@@ -7,6 +7,7 @@ const extract_webpack_options_1 = require("./lib/extract-webpack-options");
7
7
  const normalize_path_options_1 = require("./lib/normalize-path-options");
8
8
  const path_1 = require("path");
9
9
  const validate_project_1 = require("./lib/validate-project");
10
+ const versions_1 = require("../../utils/versions");
10
11
  // Make text JSON compatible
11
12
  const preprocessText = (text) => {
12
13
  return text
@@ -16,6 +17,7 @@ const preprocessText = (text) => {
16
17
  .replace(/(\r\n|\n|\r|\t)/gm, ''); // Remove newlines and tabs
17
18
  };
18
19
  async function convertConfigToWebpackPluginGenerator(tree, options) {
20
+ (0, versions_1.assertSupportedWebpackVersion)(tree);
19
21
  let migrated = 0;
20
22
  const projects = (0, devkit_1.getProjects)(tree);
21
23
  (0, internal_1.forEachExecutorOptions)(tree, '@nx/webpack:webpack', (currentTargetOptions, projectName, targetName, configurationName) => {
@@ -4,4 +4,3 @@ export declare function extractWebpackOptions(tree: Tree, webpackConfigPath: str
4
4
  withNxConfig: "" | ts.Node;
5
5
  withReactConfig: "" | ts.Node;
6
6
  };
7
- //# sourceMappingURL=extract-webpack-options.d.ts.map
@@ -1,3 +1,2 @@
1
1
  import { WebpackExecutorOptions } from '../../../executors/webpack/schema';
2
2
  export declare function normalizePathOptions(projectRoot: string, options: Partial<WebpackExecutorOptions>): Partial<WebpackExecutorOptions>;
3
- //# sourceMappingURL=normalize-path-options.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare function toProjectRelativePath(path: string, projectRoot: string): string;
2
- //# sourceMappingURL=utils.d.ts.map
@@ -7,4 +7,3 @@ import { ProjectConfiguration, Tree } from '@nx/devkit';
7
7
  * @returns A string if there is an error, otherwise undefined
8
8
  */
9
9
  export declare function validateProject(tree: Tree, project: ProjectConfiguration): string;
10
- //# sourceMappingURL=validate-project.d.ts.map
@@ -10,4 +10,3 @@ export declare function createCollectingLogger(): typeof devkitLogger & {
10
10
  flushLogs: (filter?: (message: string) => boolean) => void;
11
11
  };
12
12
  export {};
13
- //# sourceMappingURL=convert-to-inferred.d.ts.map
@@ -10,6 +10,7 @@ const versions_1 = require("../../utils/versions");
10
10
  const utils_1 = require("./utils");
11
11
  const devkit_exports_1 = require("nx/src/devkit-exports");
12
12
  async function convertToInferred(tree, options) {
13
+ (0, versions_1.assertSupportedWebpackVersion)(tree);
13
14
  const projectGraph = await (0, devkit_1.createProjectGraphAsync)();
14
15
  const migrationContext = {
15
16
  logger: new internal_1.AggregatedLog(),
@@ -1,4 +1,3 @@
1
1
  import * as ts from 'typescript';
2
2
  export declare function toPropertyAssignment(key: string, value: unknown): ts.PropertyAssignment;
3
3
  export declare function toExpression(value: unknown): ts.Expression;
4
- //# sourceMappingURL=ast.d.ts.map
@@ -4,4 +4,3 @@ export declare function buildPostTargetTransformerFactory(migrationContext: Migr
4
4
  projectName: string;
5
5
  root: string;
6
6
  }, inferredTarget: TargetConfiguration) => TargetConfiguration;
7
- //# sourceMappingURL=build-post-target-transformer.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export * from './build-post-target-transformer';
2
2
  export * from './serve-post-target-transformer';
3
3
  export * from './types';
4
- //# sourceMappingURL=index.d.ts.map
@@ -4,4 +4,3 @@ export declare function servePostTargetTransformerFactory(migrationContext: Migr
4
4
  projectName: string;
5
5
  root: string;
6
6
  }, inferredTarget: TargetConfiguration) => Promise<TargetConfiguration>;
7
- //# sourceMappingURL=serve-post-target-transformer.d.ts.map
@@ -9,4 +9,3 @@ export type TransformerContext = MigrationContext & {
9
9
  projectName: string;
10
10
  projectRoot: string;
11
11
  };
12
- //# sourceMappingURL=types.d.ts.map
@@ -3,4 +3,3 @@ import { Schema } from './schema';
3
3
  export declare function webpackInitGenerator(tree: Tree, schema: Schema): Promise<GeneratorCallback>;
4
4
  export declare function webpackInitGeneratorInternal(tree: Tree, schema: Schema): Promise<GeneratorCallback>;
5
5
  export default webpackInitGenerator;
6
- //# sourceMappingURL=init.d.ts.map
@@ -10,6 +10,7 @@ function webpackInitGenerator(tree, schema) {
10
10
  return webpackInitGeneratorInternal(tree, { addPlugin: false, ...schema });
11
11
  }
12
12
  async function webpackInitGeneratorInternal(tree, schema) {
13
+ (0, versions_1.assertSupportedWebpackVersion)(tree);
13
14
  const nxJson = (0, devkit_1.readNxJson)(tree);
14
15
  const addPluginDefault = process.env.NX_ADD_PLUGINS !== 'false' &&
15
16
  nxJson.useInferencePlugins !== false;
@@ -58,14 +59,20 @@ async function webpackInitGeneratorInternal(tree, schema) {
58
59
  }
59
60
  let installTask = () => { };
60
61
  if (!schema.skipPackageJson) {
62
+ // webpack and webpack-dev-server are peer dependencies, so ensure they are
63
+ // installed (both the executor and inferred-plugin paths need them at the
64
+ // user's runtime).
61
65
  const devDependencies = {
62
66
  '@nx/webpack': versions_1.nxVersion,
63
67
  '@nx/web': versions_1.nxVersion,
68
+ webpack: versions_1.webpackVersion,
69
+ 'webpack-dev-server': versions_1.webpackDevServerVersion,
64
70
  };
65
71
  if (schema.addPlugin) {
72
+ // The inferred plugin runs the `webpack-cli` binary.
66
73
  devDependencies['webpack-cli'] = versions_1.webpackCliVersion;
67
74
  }
68
- installTask = (0, devkit_1.addDependenciesToPackageJson)(tree, {}, devDependencies, undefined, schema.keepExistingVersions);
75
+ installTask = (0, devkit_1.addDependenciesToPackageJson)(tree, {}, devDependencies, undefined, schema.keepExistingVersions ?? true);
69
76
  }
70
77
  if (!schema.skipFormat) {
71
78
  await (0, devkit_1.formatFiles)(tree);
@@ -20,7 +20,7 @@
20
20
  "type": "boolean",
21
21
  "x-priority": "internal",
22
22
  "description": "Keep existing dependencies versions",
23
- "default": false
23
+ "default": true
24
24
  },
25
25
  "updatePackageScripts": {
26
26
  "type": "boolean",
@@ -1,3 +1,2 @@
1
1
  import { Tree } from '@nx/devkit';
2
2
  export default function (tree: Tree): Promise<void>;
3
- //# sourceMappingURL=remove-isolated-config.d.ts.map
@@ -1,3 +1,2 @@
1
1
  import { Tree } from '@nx/devkit';
2
2
  export default function (tree: Tree): Promise<void>;
3
- //# sourceMappingURL=remove-deprecated-options.d.ts.map
@@ -0,0 +1,9 @@
1
+ import { type Tree } from '@nx/devkit';
2
+ export default function migrateCreateNodesV2ToCreateNodes(tree: Tree): Promise<void>;
3
+ /**
4
+ * Rewrites named imports and re-exports of `createNodesV2` to `createNodes`
5
+ * when they come from one of the given module specifiers. Only the named
6
+ * bindings are touched — the module specifier, the `import`/`export` keyword,
7
+ * any `type` modifier, and any default import are left untouched.
8
+ */
9
+ export declare function rewriteCreateNodesV2Imports(source: string, specifiers: ReadonlySet<string>): string;
@@ -0,0 +1,134 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = migrateCreateNodesV2ToCreateNodes;
4
+ exports.rewriteCreateNodesV2Imports = rewriteCreateNodesV2Imports;
5
+ const devkit_1 = require("@nx/devkit");
6
+ const TS_EXTENSIONS = ['.ts', '.tsx', '.cts', '.mts'];
7
+ const DEPRECATED_NAME = 'createNodesV2';
8
+ const CANONICAL_NAME = 'createNodes';
9
+ // Module specifiers from which `@nx/webpack` publicly exposes `createNodesV2`.
10
+ // A named import or re-export of `createNodesV2` from one of these is rewritten
11
+ // to the canonical `createNodes` export.
12
+ const TARGET_SPECIFIERS = new Set(['@nx/webpack/plugin']);
13
+ let ts;
14
+ async function migrateCreateNodesV2ToCreateNodes(tree) {
15
+ let touchedCount = 0;
16
+ (0, devkit_1.visitNotIgnoredFiles)(tree, '.', (filePath) => {
17
+ if (!TS_EXTENSIONS.some((ext) => filePath.endsWith(ext))) {
18
+ return;
19
+ }
20
+ const original = tree.read(filePath, 'utf-8');
21
+ if (!original || !original.includes(DEPRECATED_NAME)) {
22
+ return;
23
+ }
24
+ const updated = rewriteCreateNodesV2Imports(original, TARGET_SPECIFIERS);
25
+ if (updated !== original) {
26
+ tree.write(filePath, updated);
27
+ touchedCount += 1;
28
+ }
29
+ });
30
+ if (touchedCount > 0) {
31
+ devkit_1.logger.info(`Renamed \`${DEPRECATED_NAME}\` imports to \`${CANONICAL_NAME}\` in ${touchedCount} file(s).`);
32
+ }
33
+ await (0, devkit_1.formatFiles)(tree);
34
+ }
35
+ /**
36
+ * Rewrites named imports and re-exports of `createNodesV2` to `createNodes`
37
+ * when they come from one of the given module specifiers. Only the named
38
+ * bindings are touched — the module specifier, the `import`/`export` keyword,
39
+ * any `type` modifier, and any default import are left untouched.
40
+ */
41
+ function rewriteCreateNodesV2Imports(source, specifiers) {
42
+ ts ??= (0, devkit_1.ensurePackage)('typescript', '*');
43
+ const sourceFile = ts.createSourceFile('tmp.ts', source, ts.ScriptTarget.Latest,
44
+ /* setParentNodes */ true, ts.ScriptKind.TSX);
45
+ const changes = [];
46
+ for (const stmt of sourceFile.statements) {
47
+ if (ts.isImportDeclaration(stmt)) {
48
+ collectImportRewrite(sourceFile, stmt, specifiers, changes);
49
+ }
50
+ else if (ts.isExportDeclaration(stmt)) {
51
+ collectExportRewrite(sourceFile, stmt, specifiers, changes);
52
+ }
53
+ }
54
+ return changes.length > 0 ? (0, devkit_1.applyChangesToString)(source, changes) : source;
55
+ }
56
+ function isTargetSpecifier(node, specifiers) {
57
+ return ts.isStringLiteral(node) && specifiers.has(node.text);
58
+ }
59
+ function collectImportRewrite(sourceFile, stmt, specifiers, changes) {
60
+ if (!isTargetSpecifier(stmt.moduleSpecifier, specifiers)) {
61
+ return;
62
+ }
63
+ const namedBindings = stmt.importClause?.namedBindings;
64
+ // Only `import { ... }` carries renameable named bindings. `import x`,
65
+ // `import * as ns`, and side-effect imports reference the module wholesale
66
+ // and keep working through the `createNodesV2` runtime alias, so we leave
67
+ // them be. A mixed `import def, { createNodesV2 }` still has its named
68
+ // bindings rewritten below — the default binding is untouched.
69
+ if (!namedBindings || !ts.isNamedImports(namedBindings)) {
70
+ return;
71
+ }
72
+ rewriteNamedBindings(sourceFile, namedBindings, changes);
73
+ }
74
+ function collectExportRewrite(sourceFile, stmt, specifiers, changes) {
75
+ if (!stmt.moduleSpecifier ||
76
+ !isTargetSpecifier(stmt.moduleSpecifier, specifiers)) {
77
+ return;
78
+ }
79
+ // `export { ... } from '...'` can be rewritten; `export * from '...'` has no
80
+ // named bindings to rename.
81
+ if (!stmt.exportClause || !ts.isNamedExports(stmt.exportClause)) {
82
+ return;
83
+ }
84
+ rewriteNamedBindings(sourceFile, stmt.exportClause, changes);
85
+ }
86
+ /**
87
+ * Re-renders the `{ ... }` of a named import/export, renaming any
88
+ * `createNodesV2` specifier to `createNodes`. If renaming would collide with a
89
+ * `createNodes` that is already present (e.g. `{ createNodes, createNodesV2 }`),
90
+ * the duplicate is dropped. Returns without recording a change when the binding
91
+ * list contains no `createNodesV2`.
92
+ */
93
+ function rewriteNamedBindings(sourceFile, namedBindings, changes) {
94
+ const elements = namedBindings.elements;
95
+ const hasDeprecated = elements.some((el) => (el.propertyName ?? el.name).text === DEPRECATED_NAME);
96
+ if (!hasDeprecated) {
97
+ return;
98
+ }
99
+ const seen = new Set();
100
+ const rendered = [];
101
+ for (const el of elements) {
102
+ const text = renderSpecifier(el);
103
+ if (!seen.has(text)) {
104
+ seen.add(text);
105
+ rendered.push(text);
106
+ }
107
+ }
108
+ const start = namedBindings.getStart(sourceFile);
109
+ changes.push({
110
+ type: devkit_1.ChangeType.Delete,
111
+ start,
112
+ length: namedBindings.getEnd() - start,
113
+ }, {
114
+ type: devkit_1.ChangeType.Insert,
115
+ index: start,
116
+ text: `{ ${rendered.join(', ')} }`,
117
+ });
118
+ }
119
+ function renderSpecifier(el) {
120
+ const typePrefix = el.isTypeOnly ? 'type ' : '';
121
+ const rename = (name) => name === DEPRECATED_NAME ? CANONICAL_NAME : name;
122
+ // `{ name }` — no alias, so the local binding follows the rename.
123
+ if (!el.propertyName) {
124
+ return `${typePrefix}${rename(el.name.text)}`;
125
+ }
126
+ // `{ propertyName as name }` — only the imported (left) side is renamed; the
127
+ // local alias is preserved. A now-redundant alias such as
128
+ // `createNodesV2 as createNodes` collapses to `createNodes`.
129
+ const canonicalImported = rename(el.propertyName.text);
130
+ const localName = el.name.text;
131
+ return canonicalImported === localName
132
+ ? `${typePrefix}${localName}`
133
+ : `${typePrefix}${canonicalImported} as ${localName}`;
134
+ }
@@ -0,0 +1,25 @@
1
+ #### Rename `createNodesV2` imports to `createNodes`
2
+
3
+ `@nx/webpack` renamed its primary inferred-plugin export from `createNodesV2` to `createNodes`. The `createNodesV2` name is preserved as a deprecated alias for now, but new code should use `createNodes`.
4
+
5
+ This migration scans every `.ts`, `.tsx`, `.cts`, and `.mts` file in your workspace and rewrites named imports and re-exports of `createNodesV2` from `@nx/webpack/plugin` to `createNodes`.
6
+
7
+ #### Sample Code Changes
8
+
9
+ ##### Before
10
+
11
+ ```ts
12
+ import { createNodesV2 } from '@nx/webpack/plugin';
13
+ ```
14
+
15
+ ##### After
16
+
17
+ ```ts
18
+ import { createNodes } from '@nx/webpack/plugin';
19
+ ```
20
+
21
+ Aliases are preserved (`createNodesV2 as cn` becomes `createNodes as cn`), and if a file already imports both names (`{ createNodes, createNodesV2 }`) the redundant binding is dropped.
22
+
23
+ #### What is not rewritten
24
+
25
+ Only static `import`/`export` named bindings from `@nx/webpack/plugin` are rewritten. Namespace imports, dynamic `import(...)`, `require(...)` destructuring, and property access such as `plugin.createNodesV2` are left untouched — they keep working through the `createNodesV2` runtime alias. Update those by hand if you want to drop the deprecated name everywhere.
@@ -1,3 +1,2 @@
1
1
  import { Tree } from '@nx/devkit';
2
2
  export default function removeNxTsconfigPathsWebpackPluginImport(tree: Tree): Promise<void>;
3
- //# sourceMappingURL=remove-nx-tsconfig-paths-webpack-plugin-import.d.ts.map
@@ -0,0 +1,3 @@
1
+ import { type Tree } from '@nx/devkit';
2
+ export default function rewriteInternalSubpathImports(tree: Tree): Promise<void>;
3
+ export declare function rewriteSubpathImports(source: string): string;