bounds property
An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: [sw.lng, sw.lat, ne.lng, ne.lat]
. When this property is included in a source, no tiles outside of the given bounds are requested by Mapbox GL.
Default value: -180,-85.051129,180,85.051129
.
Implementation
Future<List<double?>?> get bounds async {
return _style?.getStyleSourceProperty(id, "bounds").then((value) {
if (value.value != null) {
return (value.value as List<dynamic>).cast();
} else {
return null;
}
});
}