Marker has also a toGeoJSON method and an optional feature property like the circleMarker has

This commit is contained in:
Arne Schubert
2017-11-02 13:33:51 +01:00
parent c0d3c074f0
commit b4d0aa4d5f

View File

@@ -1457,8 +1457,9 @@ export interface MarkerOptions extends InteractiveLayerOptions {
riseOffset?: number;
}
export class Marker extends Layer {
export class Marker<P = any> extends Layer {
constructor(latlng: LatLngExpression, options?: MarkerOptions);
toGeoJSON(): geojson.Feature<geojson.Point, P>;
getLatLng(): LatLng;
setLatLng(latlng: LatLngExpression): this;
setZIndexOffset(offset: number): this;
@@ -1469,6 +1470,7 @@ export class Marker extends Layer {
// Properties
options: MarkerOptions;
dragging?: Handler;
feature?: geojson.Feature<geojson.Point, P>;
}
export function marker(latlng: LatLngExpression, options?: MarkerOptions): Marker;