[Table] Error when using ng-content
- Lingua principale
- TypeScript
- Stelle
- 25k
- Fork
- 6.8k
- Merge medio
- 1g 8h
- PR unite (30g)
- 91
Descrizione
#### Bug, feature request, or proposal:
Bug
#### What is the expected behavior?
`md-table` should wait until the `ng-content` replaced.
#### What is the current behavior?
`md-table` throws ` Cannot read property 'getColumnsDiff' of undefined`.
#### What are the steps to reproduce?
Put `ng-content` inside `md-table`.
https://plnkr.co/edit/RpOncq9lbwPcjAGjXSyR?p=preview
#### What is the use-case or motivation for changing an existing behavior?
Anyone that want to create a component with configurable `md-table` inside cannot do it.
#### Which versions of Angular, Material, OS, TypeScript, browsers are affected?
Angular: `4.4.0-RC.0` in the plunker, but this is not working with any version.
Material: `2.0.0-beta.10`
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia riproducendo il problema nel Plunker collegato con ng-content all'interno di md-table, quindi traccia quando md-table accede a getColumnsDiff rispetto alla sostituzione del contenuto proiettato. Il lavoro è completato quando md-table attende il contenuto proiettato e non genera più l'errore di proprietà undefined quando viene usato all'interno di un componente configurabile.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- angular, typescript
- Ambito
- frontend
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Tranquilla
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 58/100