1
我一直在試圖用Angular2實現一個簡單的ngForce,但我不知道哪裏出了問題,導致錯誤'Generic TYpe Array需要一個參數。請青睞通用類型'Array <T>'需要1個類型參數。 - Angular2
import { Component } from '@angular/core';
@Component({
selector: 'my-app',
templateUrl:'./app.component.html',
})
export class AppComponent {
clients:Array;
doctors:Array;
constructor(){
this.clients=["Client1", "Client2", "Client3"];
this.doctors=["Doctor1","Doctor2","Doctor3"];
}
}
讀泛型觀編程第一 –