docstring: improve default icon customization text (#5058)
detailed that modifying `L.Icon.Default.prototype.options` only customizes the icon, but it remains an image-based icon. Added a paragraph about completely replacing the default icon, so that it can now be anything (including a divIcon).
This commit is contained in:
parent
7b3c673a16
commit
aa6aa49f56
@ -7,8 +7,11 @@
|
||||
* no icon is specified. Points to the blue marker image distributed with Leaflet
|
||||
* releases.
|
||||
*
|
||||
* In order to change the default icon, just change the properties of `L.Icon.Default.prototype.options`
|
||||
* In order to customize the default icon, just change the properties of `L.Icon.Default.prototype.options`
|
||||
* (which is a set of `Icon options`).
|
||||
*
|
||||
* If you want to _completely_ replace the default icon, override the
|
||||
* `L.Marker.prototype.options.icon` with your own icon instead.
|
||||
*/
|
||||
|
||||
L.Icon.Default = L.Icon.extend({
|
||||
|
Loading…
Reference in New Issue
Block a user