DropDownButton Data Binding
The DropDownButton enables you to bind it to an array of primitive data or an array of complex data through the items prop.
Arrays of Primitive Data
The following example demonstrates how to bind the DropDownButton to an array of strings.
Arrays of Complex Data
When the DropDownButton is bound to complex data (objects), the component displays the text field of each item when it is defined. Otherwise, set textField to the name of the field that contains the display text. If an object has both text and the configured field, text takes precedence.
Data items can also set disabled, icon, svgIcon, iconClass, imageUrl, and render. For the complete list of item fields, see ButtonItemInterface.
To customize the popup item content, see Item Templates.
The following example demonstrates how to bind the DropDownButton to object data.