This looks like the simplest library for GoogleMaps, so I decided to try it.
Importing thins like this
import React, { Component } from 'react'
import ReactGoogleMaps, { Map, Marker, OverlayView } from 'react-googlemaps'
const GoogleMapsAPI = window.google.maps
class Example extends Component {
...
Also, I have the google maps script in index.html
But all I get is
ERROR in ./~/react-googlemaps/src/ReactMapComponents.js
Module not found: Error: Cannot resolve module 'react/lib/mapObject' in /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src
@ ./~/react-googlemaps/src/ReactMapComponents.js 4:16-46
ERROR in ./~/react-googlemaps/src/ui/components/ReactMap.js
Module parse failed: /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui/components/ReactMap.js Line 55: Unexpected token <
You may need an appropriate loader to handle this file type.
| if (this.state.mapLifeCycleState !== MapLifeCycle.CREATING_HOLDER) {
| map = (
| <GoogleMapsMap
| {...this.props}
| ref="map"
@ ./~/react-googlemaps/src/ui/ReactDefaultInjection.js 7:15-47
ERROR in ./~/react-googlemaps/src/ui/components/ReactOverlayView.js
Module parse failed: /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui/components/ReactOverlayView.js Line 36: Unexpected token <
You may need an appropriate loader to handle this file type.
|
| React.render(
| cloneWithProps(<div />, props),
| this._containerElement
| )
@ ./~/react-googlemaps/src/ui/ReactDefaultInjection.js 8:23-63
ERROR in ./~/react-googlemaps/src/ui/components/ReactFrag.js
Module parse failed: /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui/components/ReactFrag.js Line 24: Unexpected token <
You may need an appropriate loader to handle this file type.
|
| return (
| <span>{children}</span>
| );
| }
@ ./~/react-googlemaps/src/ui/ReactDefaultInjection.js 9:16-49
ERROR in ./~/react-googlemaps/src/ui/MapOption.js
Module not found: Error: Cannot resolve module 'react/lib/invariant' in /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui
@ ./~/react-googlemaps/src/ui/MapOption.js 3:16-46
ERROR in ./~/react-googlemaps/src/ui/MapEvent.js
Module not found: Error: Cannot resolve module 'react/lib/invariant' in /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui
@ ./~/react-googlemaps/src/ui/MapEvent.js 3:16-46
ERROR in ./~/react-googlemaps/src/GoogleMapsAPI.js
Module not found: Error: Cannot resolve module 'react/lib/invariant' in /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src
@ ./~/react-googlemaps/src/GoogleMapsAPI.js 3:16-46
ERROR in ./~/react-googlemaps/src/ui/ReactMapComponent.js
Module not found: Error: Cannot resolve module 'react/lib/invariant' in /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui
@ ./~/react-googlemaps/src/ui/ReactMapComponent.js 4:16-46
ERROR in ./~/react-googlemaps/src/ui/ReactMapComponentMixin.js
Module not found: Error: Cannot resolve module 'react/lib/invariant' in /home/seba/repos/test_applications/react-redux-cordova-boilerplate/node_modules/react-googlemaps/src/ui
@ ./~/react-googlemaps/src/ui/ReactMapComponentMixin.js 4:16-46
What's going on here?
UPDATE: exactly the same thing is happening with the examples repo. I'm starting to think it's not me messing things up
This looks like the simplest library for GoogleMaps, so I decided to try it. Importing thins like this
Also, I have the google maps script in index.html
But all I get is
What's going on here?
UPDATE: exactly the same thing is happening with the examples repo. I'm starting to think it's not me messing things up