library(leaflet)
m <- leaflet() %>% addProviderTiles("OpenStreetMap")
garnishMap(m, addMouseCoordinates)
## add more than one with named argument
library(leaflet)
m1 <- garnishMap(m, addScaleBar, addMouseCoordinates,
position = "bottomleft")
m1
Run the code above in your browser using DataLab