ckyycc / ngx-dropdown-list

Drop-down list which supports multi-selection and filter (Angular)
https://ckyycc.github.io/ngx-dropdown-list/
MIT License
4 stars 3 forks source link

I am getting error Cannot read property 'length' of undefined #2

Open sedhurabe opened 4 years ago

sedhurabe commented 4 years ago

I am using Angular 8 version in my project, Once I install the ngx-dropdown-list I got an error Cannot read property 'length' of undefined. In My html file

<ngx-dropdown-list (selectionChange)="onChange($event)"
    [items]="option"
    [(selectedValue)]="selectedName">
</ngx-dropdown-list>

In Ts file

import { optionItems } from '../../../config/config';

ngOnInit() {
    this.option = optionItems
  }