Reputation: 179
I'm trying to pass data from my parent component to my child components,
it seems that it changed from older version or i don't see what i'm doing wrong!
players = Array<PlayerModel>
here is the code:
<best-score-board [players]="players"></best-score-board>
in the bestScoreBoardComponent
import {Component, Input, NgFor} from 'angular2/angular2';
import {PlayerModel} from '../../models/players/player.ts';
@Component({
selector: 'best-score-board',
templateUrl: 'app/components/leaderboards/bestScoreBoard.html',
directives: [NgFor],
properties: [players]
})
export class BestScoreBoardComponent {
constructor() {
}
}
there is no error... but the app is not loading at all...
seeing loading... (from my main app selector loading...)
Upvotes: 0
Views: 74
Reputation: 42669
Since Angular Alpha.38, properties are renamed to inputs
. See this changeset https://github.com/angular/angular/commit/adbfd29
Upvotes: 1