diff --git a/react-leaflet/index.d.ts b/react-leaflet/index.d.ts index 2399947c7d..eff286623a 100644 --- a/react-leaflet/index.d.ts +++ b/react-leaflet/index.d.ts @@ -111,7 +111,7 @@ interface LayerProps extends LeafletInteractionEvents { interface MarkerProps extends LayerProps, LeafletDraggingEvents { position: Leaflet.LatLngExpression; draggable?: boolean; - icon?: Leaflet.Icon; + icon?: Leaflet.BaseIcon; zIndexOffset?: number; opacity?: number; } diff --git a/react-leaflet/react-leaflet-tests.tsx b/react-leaflet/react-leaflet-tests.tsx index bb78ac7264..763e719de1 100644 --- a/react-leaflet/react-leaflet-tests.tsx +++ b/react-leaflet/react-leaflet-tests.tsx @@ -179,6 +179,18 @@ export class CustomComponent extends Component { } } +export class MarkerWithDivIconExample extends Component { + render() { + return ( + + + + ) + } +} + // draggable-marker.js export class DraggableExample extends Component { state = {