Output and render functions for using howler within Shiny applications and interactive Rmd documents.
howlerOutput(outputId)
renderHowler(expr, env = parent.frame(), quoted = FALSE)
output variable to read from
An expression that generates a howler
The environment in which to evaluate expr
.
Is expr
a quoted expression (with quote()
)? This
is useful if you want to save an expression in a variable.
An output or render function that enables the use of the widget within Shiny applications.
if (interactive()) {
library(shiny)
ui <- fluidPage(
title = "howler.js Player",
howlerOutput("howler"),
howlerPlayPauseButton("howler")
)
server <- function(input, output) {
output$howler <- renderHowler(howler(c(sound = "audio/sound.mp3")))
}
shinyApp(ui, server)
}