Created
May 19, 2015 09:41
-
-
Save AmilKey/b5b0009f8cea9f445e34 to your computer and use it in GitHub Desktop.
component as collectionView
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {{#list-block content=widgets}} | |
| item value {{value}} | |
| {{/list-block}} | |
| to | |
| <ul class='list-block'> | |
| <li class='list-block__item'> | |
| item value drawer-value | |
| </li> | |
| <li class='list-block__item'> | |
| item value hot-drawer-value | |
| </li> | |
| <li class='list-block__item'> | |
| item value ext-drawer-value | |
| </li> | |
| <li class='list-block__item'> | |
| item value super-drawer-value | |
| </li> | |
| </ul> | |
| App.ListBlockComponent = App.BaseBlockComponent.extend | |
| layoutName: "components/core/list-block/template" | |
| tagName: 'ul' | |
| #template | |
| {{#each item in content}} | |
| {{list-block-item content=item}} | |
| {{/each}} | |
| App.ListBlockItemComponent = App.BaseElementComponent.extend | |
| tagName: 'li' | |
| init: ()-> | |
| @_super arguments... | |
| template = Ember.get @, 'parentView.template' | |
| Ember.set @, 'layout', template if template | |
| content = Ember.get @, 'content' | |
| @_context = content if content | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment