How to resolve React Native dependency graph stuck issue?
August 14, 2019
This summer I started my first real project on React Native v0.60.4 on a MacBook Pro with Node v12.8.0. But I could not start working on this project after adding a few dependencies. I searched through different issues. But all I tried didn’t helped me.
I tried to do all I saw on those two issues :
Unfortunately, the result was always the same…
This is how to I resolved my problem.
First, I was using a node version installed with
brew install node. But it’s better to use NVM to debug this type of issues. So simply install Node through NVM.
You could benefit from using NVM to easily update your Node version.
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh | zshcommand -v nvmnvm install nodenvm use node
At this stage, the latest version of Node worked with the Metro Bundler. But the day after, I had the same issue so I installed an older version.
nvm install 10nvm use 10
I tried it and came back to the latest with
nvm use node. It worked. I don’t have all the informations to understand why. So if someone could explain it to me, I would be glad to hear from you!
I hope this resolved your issues with React Native and how to get
Loading dependency graph, done. message.