PASSWORD RESET

Your destination for complete Tech news

How to uninstall npm modules in Node js?

373 0
< 1 min read

To uninstall an npm module in Node.js, you can use the uninstall command of the npm CLI (Command Line Interface).

The uninstall command takes the name of the module that you want to uninstall as an argument. For example:

npm uninstall express

This will uninstall the express module from your Node.js project.

You can also use the -S or --save flag to remove the module from the dependencies section of the package.json file. For example:

npm uninstall express -S

This will uninstall the express module and remove it from the dependencies section of the package.json file.

You can use the -D or --save-dev flag to remove the module from the devDependencies section of the package.json file.

npm uninstall express -D

Leave A Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.