DEV Community

Discussion on: Explain package-lock.json like I am five

Collapse
 
steelwolf180 profile image
Max Ong Zong Bao

Package-lock.json is the building instructions that comes with a Lego model.

Each package represents the different shapes or colour for a part that you eventually use to build a Lego model out of it.

Without a package-lock.json, it is like you are spreading it around and mixing with different Lego parts that do not come with the box.

By using symbols, you allow different types of the part to build your Lego model.

Which each part could be switched from an older Lego model you had brought previously or a new box of Lego model you had brought just now.