I would like to create a shiny map using leaflet which I can publish online do that others without R can view and interact with it. I can create a shiny app using leaflet, but when I use the 'publish' button in the popup window I get an error saying 'The directory to be deployed (~) exceeds the maximum deployment size, which is 100MB. Consider creating a new directory containing only the content you wish to deploy.
I can't work out what this is telling me. Does anyone have any ideas? I have posted my code below.
Thanks, Hugh
library(shiny)
library(leaflet)
shinyApp(
ui = fluidPage(leafletOutput('myMap')),
server = function(input, output) {
# download and load data
map = leaflet() %>% addTiles('http://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}.png',
attribution = paste(
'© <a href="http://openstreetmap.org">OpenStreetMap</a> contributors',
'© <a href="http://cartodb.com/attributions">CartoDB</a>'
)
) %>% setView(-122.36, 47.67, zoom = 10)
output$myMap = renderLeaflet(map)
}
)