我在 flexdashboard 中使用 shinyTree 时遇到问题。在常规闪亮的应用程序中运行良好:
library(shiny)
library(shinyTree)
server <- function(input, output) {
output$tree <- renderTree({
opciones = list('All'= list(
'Human' = structure(list('OP1'='OP1', 'OP2'='OP2'),stopened=TRUE),
'Mouse' = structure(list('OP3'='OP3'), stopened=TRUE)))
attr(opciones[[1]],"stopened")=TRUE
opciones
})
}
ui <- fluidPage(
shinyTree("tree", checkbox = "TRUE")
)
shinyApp(ui = ui, server = server)
但是,当我在 Flexdashboard 中使用它时,它会返回一个空选项卡(请参阅此文件:https ://mega.nz/file/DCozwIiJ#ttcBe581FPfhINVoczfBvaXhgRlXwVSu-wd2JhXTEEY )
您知道为什么会发生这种情况以及如何在 flexdashboard 中创建一个 js 树复选框吗?