Docs(Marker): modify icon option description (#5529)
* Docs(Marker): modify icon option description To explain that a _common_ / generic instance of `L.Icon.Default` is used, instead of leaving room to think that a _new instance_ of `L.Icon.Default` is created for every Marker without specified `icon` option. See https://github.com/Leaflet/Leaflet.markercluster/issues/786#issuecomment-302893446 * Docs(Marker): replace icon class by instance it actually needs a proper _instance_ of `L.Icon`, not a "class".
This commit is contained in:
parent
7fef7964b8
commit
f66d13976a
@ -24,7 +24,9 @@ export var Marker = Layer.extend({
|
||||
// @aka Marker options
|
||||
options: {
|
||||
// @option icon: Icon = *
|
||||
// Icon class to use for rendering the marker. See [Icon documentation](#L.Icon) for details on how to customize the marker icon. If not specified, a new `L.Icon.Default` is used.
|
||||
// Icon instance to use for rendering the marker.
|
||||
// See [Icon documentation](#L.Icon) for details on how to customize the marker icon.
|
||||
// If not specified, a common instance of `L.Icon.Default` is used.
|
||||
icon: new IconDefault(),
|
||||
|
||||
// Option inherited from "Interactive layer" abstract class
|
||||
|
Loading…
Reference in New Issue
Block a user