A selectize.js control supports optgroup
functionality, as demonstrated:
That is, in the above, "Climbing" is just a heading rather than a selectable option.
In R Shiny, this is selectize controls are produced using selectizeInput
. But how can you achieve option groups with a selectizeInput
?
This is an open issue and will probably be fixed soon
https://github.com/rstudio/shiny/issues/326
perhaps choices in selectInput() can also take a list of character vectors to generate , e.g. choices = list(Eastern = c('NY', 'MA'), Western = c('CA', 'WA'))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With