I'm getting a Failed to restore the NuGet packages with react native run-windows

Viewed 710

I'm trying to run the react-native run-windows command in my terminal but every time I run it I get this error message.

 √ Found NuGet Binary
 × Failed to restore the NuGet packages: Error: MSBuild tools not found. Make sure all required components have been installed (e.g. v141 support)

Has anyone gotten this problem before? And if so do you know the root cause of this?

1 Answers

In your visual studio installer you need to Enable the optional C++ (v141) Universal Windows Platform tools

from this link here

In visual studio 2019 it is hidden but in Installation details -> Universal Windows Platform development -> C++ (v141) Universal Windows Platform tools (Here)

It is the first time that I use react native for Windows development. I had this error because I forgot this step, so I uninstall everything and then reinstall it with this package and it worked.

Related