RagGrid icon indicating copy to clipboard operation
RagGrid copied to clipboard

renderValue needs to empty element before rendering a new one

Open hollywoof opened this issue 4 years ago • 0 comments

If you render a RagGrid from a reactive expression then the RagGrid renders multiple times.

The HTML element needs clearing inside renderValue

See what DT does on: https://github.com/rstudio/DT/blob/cd8e49fa69ddb786974fb661c275b780adcbebf9/inst/htmlwidgets/datatables.js#L117

See also a question/answer on https://stackoverflow.com/questions/44348963/replace-existing-r-shiny-htmlwidget-data-with-new-data

hollywoof avatar Jun 05 '20 13:06 hollywoof