knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

Callbacks let you pick up on events, i.e.: which slide is currently being viewed. For instance, it comes in handy to display animations at the right moment! Below are the callbacks available to each family of functions:

fullPage

pagePiling & multiScroll

Demo:

library(shiny)
library(fullPage)

ui <- fullPage(
  fullSection(
    menu = "first",
    center = TRUE,
    h1("Callbacks")
  ),
  fullSection(
    menu = "second",
    center = TRUE,
    h3("Slide"),
    verbatimTextOutput("slide")
  )
)

server <- function(input, output){

  output$slide <- renderPrint({
    input$fp_origin # returns menu
  })

}

shinyApp(ui, server)


RinteRface/fullPage documentation built on Sept. 2, 2021, 2:27 a.m.