Unable to delete node_modules? Use rimraf!!

If you have done node application development in windows machine often you might have faced issue where the node_modules directory which you created would not delete when you try to delete.

Node’s approach to package management is often criticized because of its endless nested modules folders on windows.

To solve this issue you can use the rimraf create by Nikola Breznjak by following below steps

Install rimraf

npm install -g rimraf

Delete node_modules

rimraf node_modules

Note: If you faced any issues try running the command again and it should work

Hope this helps someone like it did for me!!


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s