So, im trying to figure out how to remove some unnecessary dependencies, and I was wondering if simply deleting the dependency in the package.json file will suffice? or would I need to use npm uninstall?
CodePudding user response:
npm uninstall basically removes the files and folder and also removes the entry from package.json and package-lock.json
However, if you really need to follow deleting dependency from package.json then you can delete node_modules folder and then do npm install so only fetch dependencies that you really want to keep.
CodePudding user response:
Hi you can just delete the node_modules and dependencies from your package.json and then you can do an npm install - This will remove all packages which are not in the package.json