DefinePlugin is not not working on WebPack@5.89.0 #18389
Unanswered
MANITHIN18
asked this question in
Q&A
Replies: 1 comment
-
Please provide reproducible test repo, thank you |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When we upgraded our React front code to node 20, we also had to upgrade the Webpack from version 4 to 5. After upgrading, the global variables are not getting injected into the code at the run time in the build (dist folder). Here's the webpack config code:
So, while running the dist folder build, we are getting the error for CONSTANTS, BRAND, CONFIG, THEME and CONTENT as Undefined.
What do you think the issue could be ? any solutions?
Beta Was this translation helpful? Give feedback.
All reactions