react-native-maps

How to fix“AIRMap” was not found in the UIManager error in react native?

风格不统一 提交于 2019-12-10 12:55:43
问题 Unhandled JS Exception: Invariant Violation: requireNativeComponent: "AIRMap" was not found in the UIManager. This error is located at: in AIRMap (at MapView.js:760) in MapView (at App.js:25) in RCTView (at View.js:43) in App (at renderApplication.js:32) in RCTView (at View.js:43) in RCTView (at View.js:43) in AppContainer (at renderApplication.js:31) how to fix this error in react native ios ? 回答1: Add to ios/YOUR_PROJECT_NAME/AppDelegate.m @import GoogleMaps; //add this line if you want to

Native component for “AIRMap” does not exist

最后都变了- 提交于 2019-12-08 15:18:31
react-native: 0.53.3 react-native-maps@0.20.1 I'm trying to use react-native-maps and I keep getting this error. This is in a fresh project: react-native init maps cd maps/ npm install --save react-native-maps react-native run-ios And in App.js I've added this: ... import MapView from 'react-native-maps'; export default class App extends Component<Props> { render() { return ( <View> <MapView initialRegion={{ latitude: 37.78825, longitude: -122.4324, latitudeDelta: 0.0922, longitudeDelta: 0.0421, }} /> </View> ); } } This seems to be the bare minimum to get this running, but my iOS simulator is

Native component for “AIRMap” does not exist

£可爱£侵袭症+ 提交于 2019-12-08 04:46:32
问题 react-native: 0.53.3 react-native-maps@0.20.1 I'm trying to use react-native-maps and I keep getting this error. This is in a fresh project: react-native init maps cd maps/ npm install --save react-native-maps react-native run-ios And in App.js I've added this: ... import MapView from 'react-native-maps'; export default class App extends Component<Props> { render() { return ( <View> <MapView initialRegion={{ latitude: 37.78825, longitude: -122.4324, latitudeDelta: 0.0922, longitudeDelta: 0

Q: react-native-maps: how to use marker.showCallout() for an array of coordinates mapped as markers

允我心安 提交于 2019-12-07 23:33:07
问题 I'm currently fiddling around with react-native-maps to simulate various moving objects around a map space (simulating real time tracking of items) with a callout showing each object's name beside the marker denoting it. I'm currently able to show the callout for each marker whenever I press it. However, what I intend to do is create a button which toggles on or off the callouts for every marker on the map. I'm currently using the react-native-maps library for my map. What I've done are as

React-native-maps Blank page Only google logo

孤街浪徒 提交于 2019-12-07 03:33:58
问题 I've been trying to install google maps for react-native for a week an still no success. I've searched and tried the solutions in the react-native-maps github issue but still I get a blank page. What I do: react-native init myapp npm install yarn add react-native-maps react-native link react-native-maps In Google Console APIs -> Create new Project -> Enable Google Maps Android API, Google Maps JavaScript API and Places API -> Create credentials In AndroidManifest.xml <application> .... <meta

React Native Maps Overlapping Marker

依然范特西╮ 提交于 2019-12-06 21:55:24
问题 I use React-Native-Maps and my map marker pins that overlap each other spring apart gracefully when i click them, so can i pick the one wanted? I've used This library for the web side. 回答1: There are libraries that do this but normally it is implemented by adjusting the zoom level. Is that a possible solution or do you need to move the pins apart at the current zoom level? If you want to move them apart at the current zoom level they could push into other pins and make the issue worse. You

To enable zoom button in react-native-maps

非 Y 不嫁゛ 提交于 2019-12-06 08:18:41
I am using react-native-maps in my native project I need the default zoom control button to zoom in and out How to enable zoom button/control in react-native-maps If you rotate the screen once, with enableZoomControl=true, It will show. My problem is that it needs that rotation of the screen(device) to show the first time. 来源: https://stackoverflow.com/questions/47676655/to-enable-zoom-button-in-react-native-maps

Q: react-native-maps: how to use marker.showCallout() for an array of coordinates mapped as markers

倾然丶 夕夏残阳落幕 提交于 2019-12-06 07:48:07
I'm currently fiddling around with react-native-maps to simulate various moving objects around a map space (simulating real time tracking of items) with a callout showing each object's name beside the marker denoting it. I'm currently able to show the callout for each marker whenever I press it. However, what I intend to do is create a button which toggles on or off the callouts for every marker on the map. I'm currently using the react-native-maps library for my map. What I've done are as such: /* this.props.trackedObjects is an array of objects containing coordinate information retrieved

React-native-maps limit panning area

主宰稳场 提交于 2019-12-06 01:23:55
Is there a way to limit the map to a specific area so that panning and zooming is contained inside that area and everything outside is locked away? I would like to limit what area the user can see on the map. I am using Google Maps via react-native-maps https://github.com/react-community/react-native-maps and this is my code and currently there is no limit on how far out you can zoom or how much you can pan to either side <View style={styles.container}> <MapView style={styles.map} provider= { PROVIDER_GOOGLE } customMapStyle={mapStyle} initialRegion={{ latitude: 59.2937025, longitude: 18

React-native: How to Show the tooltip with out clicking on marker in react-native-maps

家住魔仙堡 提交于 2019-12-05 08:12:56
I am using react-native-maps module.I have given lat and long values and i have used MapView.Marker to show the Marker and tooltip when clicking on the marker. But, Now I want to show the tooltip with out clicking on the marker when the map loads initially. this is my code here: <View style={styles.page}> <MapView ref="map" style={styles.map} region={this.state.region} provider = {PROVIDER_DEFAULT} zoomEnabled={true} onRegionChange={this.onRegionChange.bind(this)} pitchEnabled={true} showsCompass={true} liteMode={false} showsBuildings={true} showsTraffic={true} showsIndoors={true} > <MapView