title: Remove zoom controls from rendered leaflet map in Shiny
body: <p>Leaflet provides an option, when setting up your map, to hide the zoom controls</p>
  
  <pre><code>leaflet(options = leafletOptions(zoomControl = FALSE)
  </code></pre>
  
  <p>However, I would like to call this option after having already created a map so that a user can download the map without the zoom controls and without me having to re-create a different version of the map from scratch.</p>
  
  <p>Here's a simple version of my app at the moment:</p>
  
  <pre><code>library(shiny)
  library(tidyverse)
  library(leaflet)
  library(mapview)
  
  ui &lt;- fluidPage(
    fluidPage(
      leafletOutput(outputId = "map"),
      downloadButton(outputId = "save")
    )
  )
  
  server &lt;- function(input, output, session) {
  
    map &lt;- reactive({
      leaflet() %&gt;%
        addTiles()
    })
  
    output$map &lt;- renderLeaflet({
      map()
    })
  
    output$save &lt;- downloadHandler(
      filename = "map.jpeg",
      content = function(file){
        latRng &lt;- range(input$map_bounds$north,
                        input$map_bounds$south)
        lngRng &lt;- range(input$map_bounds$east,
                        input$map_bounds$west)
        map() %&gt;%
          setView(lng = (lngRng[1] + lngRng[2])/2,
                  lat = (latRng[1] + latRng[1])/2,
                  zoom = input$map_zoom) %&gt;%
          ### HERE ###
          mapshot(file = file)
      }
    )
  
  }
  
  shinyApp(ui, server)
  </code></pre>
  
  <p>I'd like to be able to add a line of code where I've commented <code>### HERE ###</code> that would turn off zoom controls. In my actual code the displayed map is really complex with lots of options and I wouldn't want to have all that code twice just for the sake of removing zoom controls in the initial call to <code>leaflet()</code>.</p>
  
  <p>Thanks</p>