我正在使用ngx-chips
with autocompleteItems
for tags 输入,但添加第一个标签后,下拉列表不再出现,并且console
.
HTML
<tag-input
[ngModel]="columnsToIgnore"
[ngModelOptions]="{standalone: true}"
[placeholder]="'Enter variables to ignore'"
[secondaryPlaceholder]="'Enter variables to ignore'"
[onlyFromAutocomplete]="true"
(onAdd)="addIgnoreColumn($event)"
(onRemove)="removeIgnoreColumn($event)"
theme='bootstrap'>
<tag-input-dropdown
[autocompleteItems]="selectedDataset.schema.columns"
[displayBy]="'name'"
[focusFirstElement]="true">
<ng-template let-item="item" let-index="index">
{{ item.name }} : {{ item.type }}
</ng-template>
</tag-input-dropdown>
</tag-input>