customMarker function
Marker
customMarker(
- LatLng? latLng,
- void drag(
- LatLng
- MarkerColor markerColor = MarkerColor.red,
Custom Marker
Implementation
Marker customMarker(
LatLng? latLng,
void Function(LatLng)? drag, {
MarkerColor markerColor = MarkerColor.red,
}) =>
Marker(
draggable: true,
onDragEnd: drag,
markerId: const MarkerId('0'),
position: latLng!,
icon: colors[markerColor]!,
);