fullstackreact / react-yelp-clone

Tutorial: Build a Yelp-clone in React
https://www.fullstackreact.com/articles/react-tutorial-cloning-yelp/
MIT License
840 stars 218 forks source link

Cannot resolve module 'invariant' #6

Closed sorenbs closed 8 years ago

sorenbs commented 8 years ago

Cloning the repo, running npm i and npm start gives me the following error when I load the page.

I am running on a mac.

I have tried removing the node_modules folder and installing again, but it didn't help. Any clues?

ERROR in ./~/google-maps-react/dist/index.js
Module not found: Error: Cannot resolve module 'invariant' in /Users/sorenbs/Code/react-yelp-clone/node_modules/google-maps-react/dist
 @ ./~/google-maps-react/dist/index.js 3:4-184

ERROR in ./~/google-maps-react/dist/lib/GoogleApi.js
Module not found: Error: Cannot resolve module 'invariant' in /Users/sorenbs/Code/react-yelp-clone/node_modules/google-maps-react/dist/lib
 @ ./~/google-maps-react/dist/lib/GoogleApi.js 3:8-49
insin commented 8 years ago

This is caused by fullstackreact/google-maps-react#3

jrsl-dev commented 8 years ago

In the mean time, install invariant from npm as a dependency and you should be good to go.

hugofqueiros commented 8 years ago

+1 to fix this

auser commented 8 years ago

Fixed in google-maps-react#3.

Thanks for reporting!