我正在尝试让 react-native-maps 标记显示在我的 Android 设备上(它在 iOS 上运行良好)但它向我抛出 IndexOutofBoundsException: Invalid index 1, size is 0 error at render time。
http://i.imgur.com/owletnw.png
render() {
const INITIAL_REGION = { latitude: 52.221835, longitude: 21.000896, latitudeDelta: 0.0922, longitudeDelta: 0.0421 };
return (
<MapView ref="map"
showsUserLocation = { true }
loadingEnabled = { true }
showsTraffic = { false }
showsBuildings = { false }
style = { styles.map, {flex: 1} }
initialRegion = { INITIAL_REGION }
>
<View style={{flex: 0.1, flexDirection: 'row', position: 'absolute', justifyContent: 'space-between', …Run Code Online (Sandbox Code Playgroud)