Skip to content

fix(arborist): preserve bundleDependencies: true when saving package.json - #9958

Open
36degrees wants to merge 2 commits into
npm:latestfrom
36degrees:preserve-bundle-dependencies-true
Open

fix(arborist): preserve bundleDependencies: true when saving package.json#9958
36degrees wants to merge 2 commits into
npm:latestfrom
36degrees:preserve-bundle-dependencies-true

Conversation

@36degrees

Copy link
Copy Markdown
Contributor

If the original package.json used bundleDependencies: true, preserve that boolean value when updating package.json, rather than overwriting it with the normalized list of packages.

Note

This is my first time contributing to the codebase – please review with this in mind. I had some help from CoPilot understanding the codebase and where the change should be made, but the code changes are my own.

References

Fixes #6498

@36degrees
36degrees requested a review from a team as a code owner September 9, 2026 10:13
@36degrees
36degrees force-pushed the preserve-bundle-dependencies-true branch from 8eb0f93 to 14f8e40 Compare September 9, 2026 10:18
@36degrees 36degrees changed the title Preserve bundleDependencies: true when saving package.json fix(arborist): preserve bundleDependencies: true when saving package.json Sep 9, 2026
This 'fails' as the snapshot shows that `bundleDependencies` in package.json is normalised to an array of dependencies.
If the original package.json used `bundleDependencies: true`, preserve that boolean value when updating package.json, rather than overwriting it with the normalized list of packages.
@36degrees
36degrees force-pushed the preserve-bundle-dependencies-true branch from 14f8e40 to 3640f3c Compare September 9, 2026 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] bundleDependencies: true changed back into an array after npm install --save

1 participant