DEV Community

Discussion on: Another Npm Package Is Highjacked and It's Your Fault That This Happened

Collapse
 
jexperton profile image
Jonathan Experton

Easy, lock your dependencies

Isn’t it what a package-lock.json and npm ci do ?

From the node.js documentation

The goal of package-lock.json file is to keep track of the exact version of every package that is installed so that a product is 100% reproducible in the same way even if packages are updated by their maintainers.