You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Session$resetBrush Does Not Work For Shiny Modules #2866
Just letting you know that if you're using shiny modules to compose a Shiny app the call session$resetBrush won't work with the default input name, and you will have to compose your id by yourself.
markerDensity <- function(input, output, session) {
observeEvent(input$plot_brush, {
# THIS DOES NOT WORK
session$resetBrush("plot_brush")
# THIS DOES WORK
ns <- NS(marker_density_plot_output_module_name)
plot_brush_namespace_id <- ns("plot_brush")
session$resetBrush(plot_brush_namespace_id)
})
}
What's interesting is the input$plot_brush is detected correctly, so not sure why this is a problem
Activity
mjdall commentedon Jun 4, 2020
Session should definitely be able to reset a brush from within a namespace.
As a temporary fix, i've used:
session$resetBrush(input$brush$brushId)Which allows you to not have to reference a brush's namespace from within the module