You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+26Lines changed: 26 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -199,6 +199,32 @@ This parameter has only an effect on Android.
199
199
200
200
```
201
201
202
+
#### Using Map IDs
203
+
You can configure your map by providing a `mapId` parameter during map initialization. Map IDs are created in the [Google Cloud Console](https://console.cloud.google.com/google/maps-apis/studio/maps) and allow you to [enable various Google Maps Platform features](https://developers.google.com/maps/documentation/android-sdk/map-ids/mapid-over#features-available), such as cloud-based map styling.
204
+
205
+
> [!NOTE]
206
+
> The `mapId` can only be set once during map initialization and cannot be changed afterwards. Both `GoogleMapsMapView` and `GoogleMapsNavigationView` support the `mapId` parameter.
207
+
208
+
For `GoogleMapsMapView`:
209
+
210
+
```dart
211
+
GoogleMapsMapView(
212
+
mapId: 'YOUR_MAP_ID', // Can only be set during initialization
213
+
...
214
+
)
215
+
```
216
+
217
+
For `GoogleMapsNavigationView`:
218
+
219
+
```dart
220
+
GoogleMapsNavigationView(
221
+
mapId: 'YOUR_MAP_ID', // Can only be set during initialization
222
+
...
223
+
)
224
+
```
225
+
226
+
For more information about map IDs and how to create them, see the [Google Maps Platform documentation](https://developers.google.com/maps/documentation/get-map-id).
227
+
202
228
See the [example](./example) directory for a complete navigation sample app.
0 commit comments