`node_modules` folder is taking far more space than it should
complete
Nicolas Earnshaw
complete
I believe this issue was also fixed when we resolved the circular dependency problem
Ozymandias
The only sizeable item which remains at this point is the
@dcl/explorer
. If I won't be testing locally, it won't be needed.If I add a
"dry-uninstall"
entry in the "overrides"
section of the package.json
for "@dcl/explorer"
, I end up with a node_modules
folder that is around 10GB.Ozymandias
And anyway, in pretty much 99% of the projects that the SDK users create, the
@dcl/asset-packs
is not used.When I remove the entry from the
package.json
, I end up with a number that is finally
somewhat reasonable.💲 du node_modules --max-depth 0
273846 node_modules
Ozymandias
But guess what ! There still remains 2 copies of the
@dcl/explorer
.💲 npm ls @dcl/explorer
dcl-project@1.0.0 C:\Users\Eric\Documents\DCL\dd
├─┬ @dcl/asset-packs@1.20.0
│ └─┬ @dcl/sdk@7.5.2
│ └── @dcl/explorer@1.0.163304-20240520163732.commit-e8937d1
└─┬ @dcl/sdk@7.5.6
└── @dcl/explorer@1.0.164182-20240702173148.commit-d4a0e99
Ozymandias
When I elide the spurious
@dcl/sdk-commands
from the project using dry-uninstall
, I get again a familiar number.💲 sed -i '$e echo , \\"overrides\\": { \\"@dcl/sdk-commands\\": \\"npm:dry-uninstall\\" }' package.json
💲 npm update
removed 267 packages, changed 1 package, and audited 22 packages in 50s
💲 du node_modules --max-depth 0
552440 node_modules