Skip to content

partial_bundle() not working with Shiny #1874

Open
@lmavila

Description

@lmavila

I've been trying to use partial_bundle() so that the plotly.js distributed is smaller and my Shiny created website loads faster
When I try to use partial bundle the plot is not showing. Using chrome dev tools it shows "ReferenceError: Plotly is not defined" in plotly.js line 162

Here is a minimal example:

library(shiny)
library(plotly)
ui <- fluidPage(
    fluidRow(plotlyOutput("distPlot"))
)
server <- function(input, output) {
    output$distPlot <- renderPlotly({
        p <- plot_ly(x = 1:10, y = 1:10)%>% partial_bundle()
    })
}
shinyApp(ui = ui, server = server)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions