0
votes

Hi could anyone explain a good solution to produce the following markup using marionette

<div class="row">
 <p>itemview 1</p>
 <p>itemview 2</p>
</div>

<div class="row">
 <p>itemview 3</p>
 <p>itemview 4</p>
</div>

<div class="row">
 <p>itemview 5</p>
</div>
1

1 Answers

0
votes
CollectionView ->
  itemView : ItemView

ItemView ->
  className : 'row'
  template :
     <p>itemview 3</p>
     <p>itemview 4</p>

Edit

Ohh, seems like I understood what you want: https://github.com/marionettejs/backbone.marionette/blob/master/docs/marionette.collectionview.md#collectionviews-appendhtml

And inside this method you can create a row and insert items you want to it.