selectInput within table not rendering properly

I have tried to insert a selectInput (or selectizeInput) element inside a data frame and render it using the function DT::renderDataTable with the option escape = F. However, it seems that selectInput (or selectizeInput) rendered in this way does NOT allow me to search the entries, which is annoying, since I have a large number of entries. Any ideas on how to fix this?

Here is a reproducible example:

library(shiny)
library(tidyverse)

ui = fluidPage(DT::dataTableOutput("table_with_select"))

server = function(input, output, session) {
    
    my_table = reactive({
        df = data.frame(A = 1:5, B = 6:10)
        df[1, 1] = selectInput("select_inside_table", label = "Choose a letter", choices = c("A", "B", "C")) %>% as.character()
        df
    })
    
    output$table_with_select = DT::renderDataTable(my_table(), escape = F)
    
}

shinyApp(ui, server)

This topic was automatically closed 54 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.