Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
Meteor.call('Events.getFutureEvents', data, (err, res) => {
if (!err) {
this.setState({
events: res,
filteredEvents: res
})
this.memoizeLocations = {} // reset caching
}
this.setState({ isFetching: false })
})
}
}
}
}
const MapComponent = withScriptjs(withGoogleMap(MapComponent_))
class Map_ extends Component {
render () {
const { key } = Meteor.settings.public.gm
const url = 'https://maps.googleapis.com/maps/api/js?key=' + key + '&v=3.exp&libraries=places'
return (
}
containerElement={<div id="map-container">}
mapElement={<div id="map">}
history={this.props.history}
/>
)
}</div></div>
);
}
}
const mapState = state => ({
ipInfo: state.app.ipInfo,
offerStores: state.exchange.offerStores,
});
const mapDispatch = dispatch => ({
// rfChange: bindActionCreators(change, dispatch),
});
export default injectIntl(
connect(mapState, mapDispatch)(withScriptjs(withGoogleMap(Map))),
);
import React from 'react'
import { GoogleMap, withGoogleMap, withScriptjs } from 'react-google-maps'
const GMap = withScriptjs(
withGoogleMap(props => ),
)
export default function Map(props) {
return (
}
containerElement={<div style="{{">}
mapElement={<div style="{{">}
/>
)
}
</div></div>
scaleControl: true,
scrollwheel: true
}}
>
{this.renderActivitySegments(bounds)}
{this.renderDevices(bounds)}
{this.renderPlaces(bounds)}
{this.renderTrips(bounds)}
);
}
}
export default withScriptjs(withGoogleMap(MapContainer));
)
} else {
return (
<_ECMap
lat={props.lat}
long={props.long}
isMarkerShown={props.isMarkerShown || false}
loadingElement={<div style="{{">}
googleMapURL={`https://maps.googleapis.com/maps/api/js?key=${process.env.GOOGLE_MAPS_API}&v=3.exp&libraries=geometry,drawing,places`}
containerElement={<div style="{{">}
mapElement={<div style="{{">}/>
)
}
};
const _ECMap = withScriptjs(withGoogleMap(props => {
return (
{props.isMarkerShown &&
);
}))
export default ECMap;
</div></div></div>
import React from 'react'
import { withScriptjs, withGoogleMap, GoogleMap, Marker } from 'react-google-maps'
import '../static/styles/main.scss'
const MapGraphic = withScriptjs(withGoogleMap((props) => (
<div>
{props.isMarkerShown &&
</div>
)))
export default MapGraphic
{coords && }
containerElement={<div style="{{">}
mapElement={<div style="{{">}
coords={coords}
updateCoords={this.updateCoords}
/>}
</div>
)
}
}
const MyMapComponent = withScriptjs(withGoogleMap((props) =>
{props.isMarkerShown &&
))
export default App;</div>