Bundled dependencies are malformed. Fix or remove invalid bundledDependencies entries before publishing.
Fixes npm ERR! code EBUNDLEDINVALID npm ERR! bundledDependencies must be an array
npm pack --dry-runnpm pack --dry-runnpm ERR! code EBUNDLEDINVALIDnpm ERR! bundledDependencies must be an array
EBUNDLEDINVALID occurs when bundledDependencies is not an array of valid package names, or bundle entries are missing from dependencies.
Ensure bundledDependencies is an array of strings and each is listed in dependencies.
Delete bad entries or add proper dependency versions.
Verify the tarball before publish:
npm pack --dry-runThen publish once the bundle is correct.
Bundling is rare; prefer normal dependencies unless you have a specific offline/install reason.