-
-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refresh orderBy after *ngFor is updated? #23
Comments
|
Hi i used the below code after installing the Ng2OrderModule.but its not ordering the list by the type field.what i am doing wrong please let me know. <div *ngFor="let favorite of favoriteReports | orderBy: 'favorite.type'" title="{{favorite.title}}" class="row-striped">
<a [routerLink]="['/report/documentList',{reportId:favorite.id}]"
*ngIf="favorite.type=='Report'" (click)="selectFavorite(favorite,$event)">
<i class="fa fa-file-text"></i> {{favorite.title}}</a>
<a [routerLink]="['/report/', favorite.folderPathId]" *ngIf="favorite.type!='Report'"
(click)="selectFavorite(favorite,$event)">
<i class="fa fa-folder-open"></i> {{favorite.title}}</a>
</div> |
Try to install |
The refresh is not working for me either.
itemOrder is a property off myItem. I had to add the ticks ' for it to work as well which I did not see in the example. |
@VadimDez |
works if the pipe is stateful
|
Fixes #23, made pipe impure to detect all the changes
Fixed in latest version Thanks @ESimmonds for pointing that out. |
Thanks @VadimDez |
How to refresh the order automatic on any changes of the *ngFor?
The text was updated successfully, but these errors were encountered: