Unhandled rejection Error: EACCES: permission denied

During the execution of NPM I, NPM I suddenly went on strike. Similar error occurs below

The reason is the lack of permissions
The solution is as follows:

sudo chown -R $(whoami) ~/.npm

This line of code can easily solve this problem!!

 

Read More: