Description
I hope this is the right place to bring forward such a proposal, but I am looking for a place to discuss a possible standardization of the lock file format for package managers in the JavaScript ecosystem. There are many package managers out there, all with their own lock file formats:
- NPM —
package-lock.json
(JSON) - PNPM —
pnpm-lock.yaml
(YAML) - Yarn —
yarn.lock
(YAML) - Deno —
deno.lock
(JSON) - Bun —
bun.lock
(JSON)
Having this many different formats impacts portability for projects, essentially locking users into choosing a single package management solution and sticking with it. Moving between package managers is still possible, but could have unintended side effects, such as accidental upgrades of transitive dependencies.
Considering that all formats essentially serve the same purpose with only minor functional differences and is essentially a solved problem space, it seems like now would be a good time to unify efforts and come up with a common standard for lock files that could be implemented by all package managers.
There are some pre-existing efforts in other ecosystems that might serve as inspiration, for example Python recently adopted a new proposal to standardize a lock file format.