In this case, I am requiring request-promise, but when I start the react native project, I get the error:
"Unable to resolve module x. If you are sure the module is there, try restarting the packager."
This error is reported for every dependency of the request dependency of request-promise. I have restarted the packager as well as removing node_modules and reinstalling. In general, what does this error stem from and in the specific, what can be done to solve it?
node v4.2.1, npm v2.14.7
fetch()andPromise()should work natively out of the box. I've had luck with that just as @NaderDabit has. In order to fix module import issues I've been able to clean the project out in Xcode, rebuild it, then run it again with no errors. Have you tried that?fetch()was only available on thewindowobject.