Why does "git checkout." not change the packages of node_module that I entered by npm?

0

I made a small "poop" in my testing environment, and my system simply bugged the whole one, because npm is giving some bugs:

Git Bash:

ChromeConsole:

In the filezilla I have the old packages, the old package.json and the old node_module, but I found it strange doing git checkout I could not get my state back from the last commit.

Note: I've seen in some programming forums and in stackoverflow gringo, I would just have to reinstall some packages, but it is not giving the expected result.

    
asked by anonymous 15.03.2018 / 21:19

1 answer

1

By convention, the node_modules/ folder is ignored in the versioning of some projects, so it is not affected by the Git commands.

You can check in the file .gitignore , the path of this folder being there, it is ignored.

If this is your case, to reinstall dependencies, you can delete the node_modules/ folder and run npm install again.

    
15.03.2018 / 22:00