-
Notifications
You must be signed in to change notification settings - Fork 0
items
Evgenii Koriakin edited this page Jul 8, 2016
·
2 revisions
The data source of the component which is used to display a list of values.
Value: []
Type: Array<Object>
Sets items
field:
HTML:
<eq-combo-box #fabricsComboBox
[items]=fabrics>
</eq-combo-box>
TypeScript:
export class AppComponent {
fabrics = [
{ name: 'Cotton', id: '1' },
{ name: 'Polyester', id: '2' },
{ name: 'Cotton/Polyester', id: '3' },
{ name: 'Rib Knit', id: '4' }
];
@ViewChild('fabricsComboBox') fabricsComboBox: EqwadComboBox;
}
Gets items
field:
HTML:
<eq-combo-box #fabricsComboBox
[items]=fabrics>
</eq-combo-box>
TypeScript:
export class AppComponent {
fabrics = [
{ name: 'Cotton', id: '1' },
{ name: 'Polyester', id: '2' },
{ name: 'Cotton/Polyester', id: '3' },
{ name: 'Rib Knit', id: '4' }
];
@ViewChild('fabricsComboBox') fabricsComboBox: EqwadComboBox;
constructor() {
setTimeout(() => {
let items = this.fabricsComboBox.items;
}, 1000);
}
}