what is use of package-lock.json code example
Example 1: npm generate package-lock.json
npm install --package-lock
Example 2: how to generate package-lock.json from package.json
Have you deleted package-lock.json file? don't worry
Run below command to generate package-lock.json file in your folder.
npm i --package-lock-only
Example 3: package-lock what is it
The package-lock.json is solely used to lock dependencies to a
specific version number. So that when teammates clone your work
their dependency versions are the same as yours, or vice versa.