generateSelectOptions
Function | Source Code
generateSelectOptions(currentlySelectedValue: T, options: (SelectOption
Convenience function for generating your select options when you’d like to introduce the possibility of having an empty option.
Parameters
Section titled “Parameters”currentlySelectedValue: T
Section titled “currentlySelectedValue: T”The value that’s currently selected.
options: (SelectOption | SelectOptionGroup)[]
Section titled “options: (SelectOption | SelectOptionGroup)[]”The options for the select.
allowEmpty: boolean
Section titled “allowEmpty: boolean”Whether an empty selection is available. The empty value will have a value of ''.
allowEmptyAfterSelection: boolean
Section titled “allowEmptyAfterSelection: boolean”Whether the empty selection is available after a selection has been made.
This only has an affect if allowEmpty is true.