Angular 2.0 Release
my-component.ts:
import { Component } from 'angular2/core';
@Component({
selector: 'my-component',
templateUrl: './my-component.html'
})
export class MyComponent{
public values: number[] = [1, 2, 3];
}
my-component.html:
<div *ngFor='let value of values; trackBy: index;'>
{{ value }}
</div>
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…