vendredi 22 janvier 2016

Ember: template blocks

Is it possible with ember templates to yield 'named blocks', so that child templates can replace them? Like in Laravel, where you can:

@section('sidebar')
    This is the master sidebar.
@show

and in the child:

@section('sidebar')
    @parent
    <p>This is appended to the master sidebar.</p>
@stop

is it possible? I want to do this to add sub-view specific items to a menu bar. I added the menu bar to the application template. If this is not possible, what would be the ember way of doing that?




Aucun commentaire:

Enregistrer un commentaire