Additional "dev" dependencies in standalone output node_modules #59127
Replies: 3 comments
-
Still valid. We also noticed many additional dependencies in standalone output |
Beta Was this translation helpful? Give feedback.
-
I'm having JSDom and Vitest among others being output into chunks in standalone mode which makes no sense. It's confusing that there is zero documentation on how this process works, or how I can get this out of my bundle |
Beta Was this translation helpful? Give feedback.
-
Just realized I never added this here, there is an option to exclude files from the build via the next.config file, these are the current packages I need to exclude from being included in the node_modules
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
The standalone output of my apps were around 100Mb and It seemed a bit larger than expected. on further investigation. I noticed a couple of packages in the node_modules that seem to be dev dependencies. I deleted them and build output was dropped to 46MB. My questions are,
The folders I removed from the node_modules are
This is my next config
NB: I am using nx monorepo
Additional information
No response
Example
No response
Beta Was this translation helpful? Give feedback.
All reactions