Seamlessly Integrate 'Lottie' Animations into 'shiny' Applications

Easily integrate and control 'Lottie' animations within 'shiny' applications', without the need for idiosyncratic expression or use of 'JavaScript'. This includes utilities for generating animation instances, controlling playback, manipulating animation properties, and more. For more information on 'Lottie', see: < https://airbnb.io/lottie/#/>. Additionally, see the official 'Lottie' GitHub repository at < https://github.com/airbnb/lottie>.


shinyLottie

The ‘shinyLottie’ package allows users to easily integrate and control ‘Lottie’ animations within ‘shiny’ applications, without the need for idiosyncratic expression or use of ‘JavaScript’. This includes utilities for generating animation instances, controlling playback, manipulating animation properties, and more.

Installation

You can install the development version of ‘shinyLottie’ from GitHub with:

# install.packages("devtools")
devtools::install_github("CamHowitt/shinyLottie")

Example

Introducing ‘Lottie’ animations to a ‘shiny’ app can be accomplished using just two ‘shinyLottie’ functions:

library(shiny)
library(shinyLottie)

ui <- fluidPage(
  include_lottie(),
  lottie_animation(
    path = "shinyLottie/example.json",
    name = "my_animation"
  )
)

server <- function(input, output, session) {}

shinyApp(ui, server)

For more advanced implementations, please refer to the following articles:

  • vignette("shinyLottie")

  • vignette("Controlling-Animations")

  • vignette("Event-Listeners")

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("shinyLottie")

1.0.0 by Cameron Howitt, 2 years ago


https://camhowitt.github.io/shinyLottie/


Browse source code at https://github.com/cran/shinyLottie


Authors: Cameron Howitt [aut, cre, cph]


Documentation:   PDF Manual  


MIT + file LICENSE license


Imports shiny, jsonlite, glue, htmltools

Suggests knitr, rmarkdown


See at CRAN