When a Shiny output (such as a plot, table, map, etc.) is recalculating, it remains visible but gets greyed out. Using {shinycssloaders}, you can add a loading animation ("spinner") to outputs instead of greying them out. By wrapping a Shiny output in withSpinner()
, a spinner will automatically appear while the output is recalculating. You can also manually trigger a spinner using showSpinner()
.
In addition to showing spinners on outputs, you can also use showPageSpinner()
to show a full-page spinner that covers the entire page.
You can choose from one of 8 built-in animation types, and customize the colour/size. You can also use your own image instead of the built-in animations. See the demo Shiny app online for examples.
Need Shiny help? I'm available for consulting. If you find {shinycssloaders} useful, please consider supporting my work! ❤
This package is part of a larger ecosystem of packages with a shared vision: solving common Shiny issues and improving Shiny apps with minimal effort, minimal code changes, and clear documentation. Other packages for your Shiny apps:
Package | Description | Demo |
---|---|---|
shinyjs |