package-lock.json migration from npm v6 to v7+ lockfileVersion 2
Updating a project from npm v6 to npm v7 or later triggers an automatic migration of the package-lock.json file to lockfileVersion: 2 . This version change is designed to support new features like native workspaces and improved dependency resolution. The primary constraint is maintaining environment parity across development machines and legacy CI/CD pipelin