googleway icon indicating copy to clipboard operation
googleway copied to clipboard

`update_polylines()` does not have any impact. Ref. example in package document

Open sanjmeh opened this issue 1 year ago • 2 comments

df <- tram_route
df$id <- c(rep(1, 27), rep(2, 28))
df$colour <- c(rep("#00FFFF", 27), rep("#FF00FF", 28))
df_update <- data.frame(id = c(1,2),
                        width = c(3,10),
                        colour = c("#00FF00", "#DCAB00"))

google_map(key = map_key) %>% 
add_polylines(data = df, lat = 'shape_pt_lat', lon = 'shape_pt_lon', 
stroke_colour = "colour", id = 'id') %>% 
update_polylines(data = df_update, id = 'id', stroke_weight = "width", stroke_colour = 'colour')

In the above example the update_polylines() does not have any impact.

sanjmeh avatar Dec 25 '24 11:12 sanjmeh

from ?update_polylines

Designed to be used in a shiny application.

Is your example part of a shiny app?

dcooley avatar Dec 25 '24 11:12 dcooley

Is your example part of a shiny app?

I will confirm shortly.

sanjmeh avatar Dec 25 '24 17:12 sanjmeh