Forked from AmirTugi/angular-material-autocomplete-async-part2-component.html
Created
August 19, 2019 06:34
-
-
Save sudharsan203/5801b0d5b0561259b185f94acf0aab98 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<mat-autocomplete #auto="matAutocomplete" [displayWith]="displayFn"> | |
<mat-option *ngIf="isLoading" class="is-loading"><mat-spinner diameter="50"></mat-spinner></mat-option> | |
<ng-container *ngIf="!isLoading"> | |
<mat-option *ngFor="let user of filteredUsers" [value]="user"> | |
<span>{{ user.name }}</span> | |
<small> | ID: {{user.id}}</small> | |
</mat-option> | |
</ng-container> | |
</mat-autocomplete> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment