3

我想在我的应用程序中实现平面地图导航。请建议任何可用的库或实现它的方法。

尝试以下,但不允许添加自定义地图/楼层等。

<MapView
        style={styles.mapViewStyle}
        initialRegion={{
          latitude: 37.78825,
          longitude: -122.4324,
          latitudeDelta: 0.0922,
          longitudeDelta: 0.0421,
        }}>
        <MapView.Marker draggable
            // calloutOffset={MapView.Marker.Point{x:0, y:30}}
            pinColor='steelblue'
            coordinate={{latitude: 37.78825,longitude: -122.4324,}}
            title='San Francisco'
            description='City by the Bay'
            onDragEnd={(e) => this.setState({ x: e.nativeEvent.coordinate })}
          />
    </MapView>
4

1 回答 1

1

您可以从 Airbnb 自定义react-native-maps 之类的东西,对于实现部分,我们不会在本网站按需提供代码,首先您必须向我们展示您尝试过的内容 :)

希望能帮助到你!

于 2016-09-30T13:13:47.730 回答