style property
dynamic
get
style
The map's Mapbox style. This must be an a JSON object conforming to the schema described in the Mapbox Style Specification, or a URL to such JSON.
To load a style from the Mapbox API, you can use a URL of the form mapbox://styles/:owner/:style
,
where :owner
is your Mapbox account name and :style
is the style ID. Or you can use one of the following
the predefined Mapbox styles:
mapbox://styles/mapbox/streets-v11
mapbox://styles/mapbox/outdoors-v11
mapbox://styles/mapbox/light-v10
mapbox://styles/mapbox/dark-v10
mapbox://styles/mapbox/satellite-v9
mapbox://styles/mapbox/satellite-streets-v11
mapbox://styles/mapbox/navigation-preview-day-v4
mapbox://styles/mapbox/navigation-preview-night-v4
mapbox://styles/mapbox/navigation-guidance-day-v4
mapbox://styles/mapbox/navigation-guidance-night-v4
Tilesets hosted with Mapbox can be style-optimized if you append ?optimize=true
to the end of your style URL, like mapbox://styles/mapbox/streets-v11?optimize=true
.
Learn more about style-optimized vector tiles in our API documentation.
Implementation
dynamic get style => jsObject.style;