metacran downloads

metacran downloads

Travis build status

R badge

scrollrevealR allows you to animate shiny elements when they scroll into view using the scrollrevealjs library.


You can install the scrollrevealR package from CRAN with:


You can install the development version of scrollrevealR from GitHub with:

# install.packages("devtools")


In order to use scrollrevealR, you only need to use one function:

Important: when you apply the scroll_reveal() function on Shiny Tables, they tend to disappear when you scroll down to check the last observations of the table which is annoying. In order to deal with this issue, you can use the reset = FALSE argument which will trigger an animation only once.

Below an example of a simple shiny app that uses the scrollrevealR package:


ui <- fluidPage(

  h1("Mtcars Plot"),

  br(), br(),

  plotOutput(outputId = "plt1"),

  br(), br(),

  h1("Iris Plot"),
  plotOutput(outputId = "plt2"),

  br(), br(),

  h1("ChickWeight Plot"),

  plotOutput(outputId = "plt3"),

  # Using the scroll_reveal() function -------------------------------------------
  scroll_reveal(target = c("#plt1", "#plt2", "#plt3"), duration = 2000, distance = "100px"),

  scroll_reveal(target = "h1", duration = 2000, distance = "100px"),
  # ----------------------------------------------------------------------------- 

  # Making some space at the end

  br(), br(), br(), br(), br(), br(), br(), br(), br(), br(), br(), br()


server <- function(input, output) {

output$plt1 <-  renderPlot({



output$plt2 <- renderPlot({



output$plt3 <- renderPlot({




shinyApp(ui = ui, server = server)

Commercial License

If you use the scrollrevealR package for commercial usage, You can buy a Commercial License from the scrollreveal website.

Code of Conduct

Please note that the scrollrevealR project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.