Mapbox.Maui
10.11.1
See the version list below for details.
dotnet add package Mapbox.Maui --version 10.11.1
NuGet\Install-Package Mapbox.Maui -Version 10.11.1
<PackageReference Include="Mapbox.Maui" Version="10.11.1" />
paket add Mapbox.Maui --version 10.11.1
#r "nuget: Mapbox.Maui, 10.11.1"
// Install Mapbox.Maui as a Cake Addin #addin nuget:?package=Mapbox.Maui&version=10.11.1 // Install Mapbox.Maui as a Cake Tool #tool nuget:?package=Mapbox.Maui&version=10.11.1
Mapbox for MAUI
A dedicated library and starting sample for integrating Mapbox into your MAUI application.
Installation
Install-Package Mapbox.Maui --version 10.11.1
Setup
1/ MAPBOX_DOWNLOADS_TOKEN
All Mapbox libraries required an access token to download them for use. Please follow the guide from Mapbox and go the dashboard of your Mapbox account and grab one.
a/ Android
On Android, we will leverage the gradle way of downloading Mapbox native libraries, please set MAPBOX_DOWNLOADS_TOKEN
property and put it in ~/.gradle/gradle.properties
as below example
MAPBOX_DOWNLOADS_TOKEN=YOUR_MAPBOX_DOWNLOADS_TOKEN
b/ iOS
oOn iOS, we will need to edit iOS's CSPROJ file to have MAPBOX_DOWNLOADS_TOKEN
property as below example.
<Project ...>
...
<PropertyGroup>
<MAPBOX_DOWNLOADS_TOKEN>YOUR_MAPBOX_DOWNLOADS_TOKEN</MAPBOX_DOWNLOADS_TOKEN>
</PropertyGroup>
...
</Project>
2/ Android addtional setup As Mapbox has its own private Gradle repository, we need to add these lines to Android's CSPROJ file.
<Project ...>
...
<ItemGroup>
<GradleRepository Include="https://api.mapbox.com/downloads/v2/releases/maven">
<Repository>
maven {
url 'https://api.mapbox.com/downloads/v2/releases/maven'
authentication {
basic(BasicAuthentication)
}
credentials {
// Do not change the username below.
// This should always be `mapbox` (not your username).
username = "mapbox"
// Use the secret token you stored in gradle.properties as the password
password = MAPBOX_DOWNLOADS_TOKEN
}
}
</Repository>
</GradleRepository>
</ItemGroup>
...
</Project>
2/ YOUR_ACCESS_TOKEN
To display Mapbox Map in your app, you will need another access token which can be easily grabbed by following the guide from Mapbox.
You can set it conventionally in strings.xml
for Android or in info.plist
for iOS. Otherwise, you can also set the value in code as the guide from Mapbox documetation.
a/ Android's strings.xml
<string name="mapbox_access_token">YOUR_MAPBOX_ACCESS_TOKEN</string>
b/ iOS's info.plist
<key>MBXAccessToken</key>
<string>YOUR_MAPBOX_ACCESS_TOKEN</string>
Ported Examples
NOTE: A handy command to generate a new example
dotnet cake -- --name SymbolClustering --index 58 --group Annotations --title "Add Cluster Symbol Annotations" --subtitle "Show fire hydrants in Washington DC area in a cluster using a symbol layer."
Known issues
- The library is not yet able to build to run on iOS real device. Issue
Maintainer
This project is maintained by tuyen-vuduc in his spare time and/or when requested.<br>
If you find this project is helpful and benefit your work/business, please give it a star, become a sponsor of the project and/or buy him a coffee.
LICENSE
This library is release under The BSD 3-Clause License. You are freely to use and make changes. However, this license doesn't override the license from Mapbox.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0-android31.0 is compatible. net6.0-ios16.1 is compatible. net7.0-android was computed. net7.0-ios was computed. net8.0-android was computed. net8.0-ios was computed. net9.0-android was computed. net9.0-ios was computed. |
-
net6.0-android31.0
- Com.Mapbox.Maps.Android (>= 10.11.1)
- GeoJSON.Text (>= 1.0.2)
- Microsoft.Extensions.Logging.Debug (>= 7.0.0)
- Square.OkHttp3 (>= 4.10.0.1)
- Xamarin.AndroidX.Annotation (>= 1.6.0.2)
- Xamarin.Build.Download (>= 0.11.4)
- Xamarin.Kotlin.StdLib (>= 1.8.21.1)
- Xamarin.Kotlin.StdLib.Jdk8 (>= 1.8.21.1)
-
net6.0-ios16.1
- GeoJSON.Text (>= 1.0.2)
- MapboxMapsObjC.iOS (>= 10.11.1)
- MapboxMobileEvents.iOS (>= 1.0.10)
- Microsoft.Extensions.Logging.Debug (>= 7.0.0)
- System.Runtime.InteropServices.NFloat.Internal (>= 6.0.1)
- Xamarin.Build.Download (>= 0.11.4)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
11.8.0-alpha01 | 87 | 12/3/2024 |
11.7.1-alpha02 | 97 | 10/29/2024 |
11.6.0-alpha02 | 101 | 9/18/2024 |
11.6.0-alpha01 | 114 | 9/10/2024 |
11.5.1-alpha09 | 246 | 9/4/2024 |
11.5.1-alpha08 | 86 | 8/27/2024 |
11.5.1-alpha07 | 99 | 8/26/2024 |
11.5.1-alpha06 | 93 | 8/26/2024 |
11.5.1-alpha05 | 104 | 8/21/2024 |
11.5.1-alpha04 | 111 | 8/20/2024 |
11.5.1-alpha03 | 100 | 8/15/2024 |
11.5.1-alpha02 | 108 | 8/12/2024 |
11.5.1-alpha01 | 111 | 8/9/2024 |
11.5.0-alpha03 | 92 | 8/1/2024 |
11.5.0-alpha02 | 107 | 7/19/2024 |
11.5.0-alpha01 | 91 | 7/12/2024 |
11.4.0-alpha02 | 108 | 7/9/2024 |
11.4.0-alpha01 | 165 | 6/28/2024 |
11.3.0-alpha04 | 108 | 6/27/2024 |
11.3.0-alpha03 | 97 | 6/25/2024 |
11.3.0-alpha02 | 99 | 6/25/2024 |
11.1.0-alpha01 | 174 | 2/28/2024 |
10.11.1.1 | 665 | 7/20/2023 |
10.11.1 | 299 | 7/15/2023 |