ericrayanderson/shinymaterial

[bug] material_button : observe won't works with renderUI

Opened this issue · 1 comments

Hi,

It seems observe won't work with renderUI :

library(shiny)
library(shinymaterial)

ui <- material_page(
  title = "Test",
  material_row(
    material_button("test", "Observe works with material_button"),
    uiOutput("renderUI_material_button")
  )
)

server <- function(input, output){
  
  output$renderUI_material_button <- renderUI({
    material_button("test2", "Observe don't works with renderUI material_buttons")
  })
  
  observeEvent(input$test, {
    print('Material works !')
  })
  
  observeEvent(input$test2, {
    print('Render UI material buttons works !')
  })
  
}

shinyApp(ui, server)

Thanks

Hi, i had this problem. No happen with default shiny button.