I've been wondering about this too... Doesn't seem like you can extend
the base L.Control class with just the distribution code, though that
other examples I've seen I'm guessing you need to do a full build.
On Apr 29, 3:38 pm, Elliott <elliotthuns...@gmail.com
> Hi all,
> I've been trying to extend leaflet's L.Control, much in the same way as
> control.layers, attribution, scale and zoom.
> My aim has been to make a new control type to sit in the corner of a map,
> where buttons could be programmatically added and removed by a script
> (which would set their icon url and text), and callback functions added to
> click events on those buttons. I've managed to cobble together an examplehttp://imgur.com/DBKXl
> - Is extending L.Control the best way to go about this?
> - Do I then have to rebuild all of leaflet, or is it possible to just
> include my 'leaflet-control-buttons.js' file along with the cdn-served
> - Feature requests/ideas that I could include?