Quantcast
Channel: Ember.JS - Latest topics
Viewing all articles
Browse latest Browse all 4828

How to pass in a template as a property

$
0
0

@ondrejsevcik wrote:

Hi, I have a table component that accepts columns and I would like to pass as a part of a column definition how the content of that column should be rendered.

<CustomTable
  @columns={{array
    (hash 
      title='Name' 
      template=(user => <strong>{{user.name}}</strong>) // <- here
    )
  }}
  @items={{this.users}}
/>

Is there a way to achieve this?

Posts: 3

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 4828

Trending Articles