toJson method
Converts a MarkerShape object to a JSON map, or null if shape is null.
Uses the toJson method of the MarkerShape instance, which returns a map with 'type' and any additional properties.
Implementation
@override
Map<String, dynamic>? toJson(MarkerShape? shape) {
return shape?.toJson();
}