react-native-mapbox-navigation-v3
v0.1.6
Published
React Native Navigation using v3 of mapbox navigation sdk for android
Downloads
12
Maintainers
Readme
react-native-mapbox-navigation
Navigating using mapbox V3 core framework (android only for now)
Installation
npm install react-native-mapbox-navigation
Usage
Dentro de la carpeta android: en gradle.properties añadir {
MAPBOX_DOWNLOADS_TOKEN=SECRET_TOKEN_HERE
}.
en gradle.build añadir {
allprojects {
repositories {
maven {
url 'https://api.mapbox.com/downloads/v2/releases/maven'
authentication {
basic(BasicAuthentication)
}
credentials {
username = "mapbox"
password = project.properties['MAPBOX_DOWNLOADS_TOKEN'] ?: ""
}
}
}
}
}.
En android/app/src/main/AndroidManifest.xml
añadir
<!-- Tiene que estar dentro de application -->
<meta-data android:name="MAPBOX_ACCESS_TOKEN"
android:value="PUBLIC_TOKEN_HERE" />
import { MapboxNavigationView } from "react-native-mapbox-navigation";
// ...
<MapboxNavigationView origin={[]} destination={[]} waypoints={[]} />
Contributing
See the contributing guide to learn how to contribute to the repository and the development workflow.
License
MIT
Made with create-react-native-library