A collection of loading spinners animated with CSS
Arguments
- uiOutput
An output element to be wrapped within a spinner.
- type
Type of spinner to use. Any integer between
1
and8
is valid.- color
Color of the spinner. Choose between hexadecimal or keyword values.
Examples
if (interactive()) {
library(shiny)
shinyApp(
ui = fluidPage(
useSpinners(),
actionButton("render", "Render"),
spinners(plotOutput("plot"))
),
server = function(input, output) {
output$plot <- renderPlot({
input$render
Sys.sleep(3)
hist(mtcars$mpg)
})
}
)
}