Replies: 3 comments 7 replies
-
@kindy91 Thanks for your detailed issue report. I’ll look into the cause of the changes in 5.101.1. |
Beta Was this translation helpful? Give feedback.
-
I tried creating a demo using the provided webpack.config.js, but I wasn’t able to reproduce the issue. |
Beta Was this translation helpful? Give feedback.
-
@kindy91 Could you provide more details about the error stack trace, as well as the relevant section of the bundled code where the error occurs? That would help us better understand what’s happening. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Introduction and Setup
I use
angular
andngx-build-plus
for a microfrontend - host application. Lately, after migrating to the latest angular version, i receive the following run time error IN PRODUCTION, NOT LOCALLY when loading the microfrontend in the host application.__webpack_exports__ is not defined
After some debugging, the migration to that angular version, uses
webpack: 5.101.2
which is causing the current behavior for me for some reason i can't understand.The following is my package setup
PS: When i override
webpack
to version5.101.0
, i don't see the bug no more. So i know definetly it happens after thatMoreover, my microfrontend webpack config looks like follows: ( CommonJs ES5 config )
Debugging
webpack
to version5.101.0
removes the issue.Check the following 2 screenshots from the network calls where i run the host one time on production and one time locally as production using
ng serve --configuration production
Localhost ( run as production )
Production
Possible Causes
- After checking what was released in `5.101.1`, saw the following points that i think can be the cause for the bug.https://github.com/webpack/webpack/releases/tag/v5.101.1
While i assume this is the reason it is happenning, i am not sure where the bug actually is happenning, and therefore where the fix can be applied, whether:
ngx-build-plus
library?I would love to get some suggestions from the community, as i am out of solutions.
FYI: these are the support tickets i openned around a month ago in
angular
andngx-build-plus
.angular/angular#63413
manfredsteyer/ngx-build-plus#419
Beta Was this translation helpful? Give feedback.
All reactions