@@ -62,8 +62,9 @@ JC may be available to work remotely and can be contacted at these links:
62
62
* [ Add Nx Packages for Angular and React] ( #add-nx-packages-for-angular-and-react )
63
63
* [ Add the Nx Package for Angular] ( #add-the-nx-package-for-angular )
64
64
* [ Add the Nx Package for React] ( #add-the-nx-package-for-react )
65
- * [ Fix the Nx Buf for NPM Install Error] ( #fix-the-nx-bug-for-npm-install-error )
66
- * [ Fix the Nx Bug for Build Error] ( #fix-the-nx-bug-for-build-error )
65
+ * [ Fix the Nx Package Bugs] ( #fix-the-nx-package-bugs )
66
+ * [ Fix the NPM Install Error Bug] ( #fix-the-npm-install-error-bug )
67
+ * [ Fix the Nx Build Error Bug] ( #fix-the-nx-build-error-bug )
67
68
* [ Generate the Angular Host App and Two Remotes] ( #generate-the-angular-host-app-and-two-remotes )
68
69
* [ Commit and Push the Changes for the Angular Host App] ( #commit-and-push-the-changes-for-the-angular-host-app )
69
70
* [ Build and Run the Host Application] ( #build-and-run-the-host-application )
@@ -151,20 +152,24 @@ nx add @nx/angular
151
152
nx add @nx/react
152
153
```
153
154
154
- ### Fix the Nx Bug for NPM Install Error
155
+ ### Fix the Nx Package Bugs
155
156
156
- If you get an error when running the ` npm install ` command,
157
- you will need to fix the error or use the ` --force ` option .
157
+ At this time, there are two bugs in the Nx packages.
158
+ You will need to change a few things in the ` package.json ` file to fix them .
158
159
159
- This error is caused by a dependency conflict between the packages that this version of nx uses .
160
- This is a known issue .
160
+ These bugs should be fixed in the next release of Nx .
161
+ So you should first try to run the NPM Install and Nx Build commands before making these changes .
161
162
162
- https://github.com/nrwl/nx/issues/32530
163
+ #### Fix the NPM Install Error Bug
164
+
165
+ If you get an error when you run ` npm install ` in the terminal window,
166
+ you will need to change the ` package.json ` file, to lower the version of ** jest** .
167
+
168
+ Here is the Nx Issue:
163
169
164
- I was able to fix the error by changing the ` package.json ` file as follows.
170
+ https://github.com/nrwl/nx/issues/32530
165
171
166
- * Change the version of jest and related items from 30.0.2 or 30.0.0 to 29.5.0.
167
- * Change the version of jest-preset-angular from 15.0.0 to 14.6.1.
172
+ In the ` package.json ` file, change the following lines to this:
168
173
169
174
```
170
175
"@types/jest": "^29.5.0",
@@ -175,22 +180,25 @@ I was able to fix the error by changing the `package.json` file as follows.
175
180
"jest-util": "^29.5.0",
176
181
```
177
182
178
- ### Fix the Nx Bug for Build Error
183
+ #### Fix the Nx Build Error Bug
179
184
180
- If you get an error when running the ` nx build` or ` nx serve` command ,
181
- you will need to fix the error .
185
+ If you get an error when you try to build or serve the project ,
186
+ you will need to change the ` package.json ` file, to add a package .
182
187
183
- There is a bug in the Nx build process that causes the build to fail.
184
- This is a known issue.
188
+ Here is the Nx Issue:
185
189
186
190
https://github.com/nrwl/nx/issues/32542
187
191
188
- The workaround is to add rspack to your ` package.json ` , ` devDependencies ` as follows.
192
+ Add this line to the ` package.json ` file, under the ` devDependencies ` section::
189
193
190
194
```
191
195
"@rspack/core": "1.4.11",
192
196
```
193
197
198
+ Delete the ` node_modules ` directory and the ` package-lock.json ` file.
199
+
200
+ Run ` npm install ` again.
201
+
194
202
Commit and push the changes.
195
203
196
204
## Generate the Angular Host App and Two Remotes
0 commit comments