Skip to main content

Expo Setup

[!Important] This package cannot be used with the "Expo Go" app because it is not part of the Expo SDK.

First install the @maplibre/maplibre-react-native with expo or the package manager of your choice:

npx expo install @maplibre/maplibre-react-native

After installing the package, add the config plugin to the plugins array of your app.json or app.config.{js,ts}:

{
"expo": {
"plugins": [
"@maplibre/maplibre-react-native"
]
}
}

Next, rebuild your app as described in the "Add custom native code" guide.

The plugin is required to properly install MapLibre Native on iOS, where it adds $MLRN.post_install(installer) to the post_install block in the ios/Podfile. On Android it only serves customizations.

Plugin Props

The plugin allows to customize the setup of MapLibre React Native through plugin props. Find out more in the customization guide.