4

I wish to use the ColVis plugin with DataTable in shiny.

ColVis

The plugin provides the user with a nice button/dropdown selection menu to control column visibility.

In my latest attempt to get this working, I have:

  • added dataTables.colVis.js to my app's wwww directory
  • tried includeScript("www/dataTables.colVis.js")
  • also tried tags$head(tags$script(src="dataTables.colVis.js")) as a MainPanel argument
  • see no errors, in R, or in the Chrome console
  • but see no button providing access to column selection

I am accustomed to debugging javascript, but at a loss here for finding and debugging the javascript created from ui.R by Shiny.

Are there tutorials on how to debug a shiny a shiny app at the level of javascript? Has anyone had success using ColVis in shiny? Is there a better, Shiny-native way to allow the user easy access to hide/display DataTable columns?

Thanks,

  • Paul
paul shannon
  • 355
  • 5
  • 15

1 Answers1

1

Have a look at new package from RStudio DT (https://github.com/rstudio/DT)? Here http://rstudio.github.io/DT/extensions.html you could find an example of what you need.

kismsu
  • 1,049
  • 7
  • 22