Posts

Showing posts with the label react-native-maps

React native map integration

I am trying to integrate map in react native. I am following the below tutorial. https://github.com/airbnb/react-native-maps I gone through all the installation instruction. I am using react-native version : 0.44.0 and react-native-map version : 0.13.0 I made sure that react-native-link is linked with android and iOS. While rendering the mapview in ios simulator, map is not showing and only i am able to a blank map with red outline. Please check my below code and let me know, where i am wrong. var MapView = require('react-native-maps'); <MapView initialRegion={{ latitude: 37.78825, longitude: -122.4324, latitudeDelta: 0.0922, longitudeDelta: 0.0421, }} /> Try adding a View and some heights and ...StyleSheet.absoluteFillObject <View style={{height:400}}> <MapView style={{ ...StyleSheet.absoluteFillObject,height:400 }} initialRegion={{ latitude: 37.78825, longitude: -...

react native can't install react-native-maps (Android)

I can't install react native react-native-maps, i get this error when i try to build with react-native run-android (I didn't try on iOS yet) : A problem occurred configuring project ':app'. Could not resolve all dependencies for configuration ':app:_debugApk'. Configuration with name 'default' not found. I followed the instructions here : https://github.com/airbnb/react-native-maps/blob/master/docs/installation.md when i run : react-native link I get : rnpm-install info iOS module react-native-maps is already linked rnpm-install info Android module react-native-geocoder is already linked rnpm-install info iOS module react-native-geocoder is already linked It seams that it worked on iOS but not on android although for geocoder it worked (and the service is working fine). So i follwed manual instructions and edited (but i still get the error above) : android/app/build.gradle android/settings.gradle MainApplication.j...

Integrate react-native-starter-kit & react-native-maps

How can I add maps function to the starter kit? https://github.com/react-community/react-native-maps https://github.com/mcnamee/react-native-starter-kit It seems using Expo? Do I have to eject the project? And then Android & IOS has to be develop separately after that? Thank you!

React Native: Style UserLocation in react-native-maps

How to style the ‍ UserLocation on React Native Maps <MapView region={this.props.coordinate} showsUserLocation={true} // <- style for this option > //My map markers </MapView> Style such as { position:"absolute", top:100, right:100, } You can not directly styling mapView component. All you can do is place mapView inside a normal View and you can styling the View as much as you want. You can place the style at your separated .js file, i guess with "style" suffix in its filename.

clustring react-native-maps in react native map

I tried react native map clustering with super cluster and react-native-maps(airbnb) by using this reference which show poor performance for more nodes, to improve this where to start either airbnb java code or super cluster. There is a solution, using supercluster, and here an example ! https://github.com/warka0/react-native-cluster-example

React Native react-native-maps

I have a question about pushing and updating drops without updating the state of a component. I currently have a parent component, and inside with the react-native-maps component with marker components. If I want to update these markers or add new markers, I have to do it through state that gets passed down as a property. The problem I am having is each time I do this, the map is redrawn and I am moved back to the initial coordinates. Is it possible to update the maps markers and properties through some sort of push method or direct manipulation. Essentially, I would like to add or remove markers from the map, and change their custom image without the map redrawing. https://github.com/react-community/react-native-maps

React-native not able to uninstall react-native-maps

Receiving following error when try to uninstall $ npm uninstall --save react-native-maps/ npm WARN react-dom@15.5.4 requires a peer of react@^15.5.4 but none was installed. npm WARN react-native@0.44.0 requires a peer of react@16.0.0-alpha.6 but none was installed. npm WARN react-native-elements@0.9.7 requires a peer of react-native-vector-icons@~4.0.0 but none was installed. npm WARN react-native-maps@0.13.0 requires a peer of react@>=15.4.0 but none was installed. npm WARN react-native@0.41.2 requires a peer of react@~15.4.0 but none was installed. npm WARN react-native-windows@0.41.0-rc.0 requires a peer of react-native@~0.41.0 but none was installed. npm WARN react-native-windows@0.41.0-rc.0 requires a peer of react@~15.4.0 but none was installed. npm WARN react-static-container@1.0.1 requires a peer of react@^0.13.0 || ^0.14.0 || ^15.0.0 but none was installed. npm WARN react-test-renderer@15.4.2 requires a peer of react@^15.4.2 but none was installed. Can someone tell,...