lastinngfor

1.0.0 • Public • Published

Get trigger in last element of ngFor loop

headersprovider

Get trigger in last element of ngFor loop

Installation instruction

npm install lastinngfor --save

Instruction to use the package

How to use?

instruction for how to use

    import { LastDirective } from "lastinngfor";; //in module

    declarations: [
         LastDirective
    ]

    import { LastDirective } from "lastinngfor";; //in your component

    <div *ngFor="let item of arrayList; let last = last" [isLast]="last" (lastDone)="onlast(last)">

    //in your component
    onlast(obj:any){
        console.log('onlast called : '+obj);
        if(obj===true) {
            //write your code here
        }
    }

Package Sidebar

Install

npm i lastinngfor

Weekly Downloads

77

Version

1.0.0

License

MIT

Unpacked Size

1.57 kB

Total Files

4

Last publish

Collaborators

  • vashramberani