如何在 Angular 2处获得索引但增加1:
<li *ngFor="let mPrepTasks of project.upcomingMeetingsPrepTask; let i= index; let count = i+ 1;">
<p>Index {{count}}</p>
</li>
最佳答案
为什么不这样做:
<li *ngFor="let mPrepTasks of project.upcomingMeetingsPrepTask; let i= index;">
<p>Index {{i + 1}}</p>
</li>
关于angular - ngFor 索引加 1 或计数加 1,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39275784/