I got "dumb" list component that uses another "dumb" component to render single item. And when I want to pass data to renderers I got to have same property in my list component. For example if I want to have "showTimestamp" boolean property for item I got to do this:
list.template.html
<my-item-renderer *ngFor="let item of items" [showTimestamp]="showTimestamp"></my-item-renderer>
Is there a way to do something to replace part of component template?
I would like to do something like this:
<my-list [items]="items"><ng-content><item-renderer [showTimestamp]="true"></item-renderer></ng-content></my-list>
So my list get just items property and in ng-content gets a renderer with already set showTimestamp variable.