pin_reactive_read()
and pin_reactive_download()
wrap the results of
pin_read()
and pin_download()
into a Shiny reactive. This allows you to
use pinned data within your app, and have the results automatically
recompute when the pin is modified.
Usage
pin_reactive_read(board, name, interval = 5000)
pin_reactive_download(board, name, interval = 5000)
Arguments
- board
A pin board, created by
board_folder()
,board_connect()
,board_url()
or anotherboard_
function.- name
Pin name.
- interval
Approximate number of milliseconds to wait between re-downloading the pin metadata to check if anything has changed.
Examples
if (FALSE) {
library(shiny)
ui <- fluidPage(
tableOutput("table")
)
server <- function(input, output, session) {
board <- board_local()
data <- pin_reactive_read(board, "shiny", interval = 1000)
output$table <- renderTable(data())
}
shinyApp(ui, server)
}