Last active
August 3, 2016 13:34
-
-
Save belackriv/87cc3fa6ac8811af6a9579992d391555 to your computer and use it in GitHub Desktop.
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
'use strict'; | |
import Marionette from 'marionette'; | |
import viewTpl from './boxItemView.hbs!'; | |
import TrashListView from './trashListView.js'; | |
export default Marionette.LayoutView.extend({ | |
template: viewTpl, | |
tagName: 'li', | |
regions: { | |
'trash': '[data-region="trash"]', | |
}, | |
onRender(){ | |
let trashListView = new TrashListView({ | |
collection: this.model.get('trash'), | |
}); | |
this.showChildView('trash', trashListView) | |
}, | |
}); |
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
'use strict'; | |
import Marionette from 'marionette'; | |
import BoxItemView from './boxItemView.js'; | |
export default Marionette.CollectionView.extend({ | |
tagName: 'ul', | |
childView: BoxItemView | |
}); |
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
'use strict'; | |
import Marionette from 'marionette'; | |
import viewTpl from './dumpsterView.hbs!'; | |
import BoxListView from './boxListView.js'; | |
export default Marionette.LayoutView.extend({ | |
template: viewTpl, | |
regions: { | |
'boxes': '[data-region="boxes"]', | |
}, | |
onRender(){ | |
let boxListView = new BoxListView({ | |
collection: this.model.get('boxes'), | |
}); | |
this.showChildView('boxes', boxListView) | |
}, | |
}); |
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
'use strict'; | |
import Marionette from 'marionette'; | |
import viewTpl from './trashItemView.hbs!'; | |
export default Marionette.LayoutView.extend({ | |
template: viewTpl, | |
tagName: 'li' | |
}); |
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
'use strict'; | |
import Marionette from 'marionette'; | |
import TrashItemView from './trashItemView.js'; | |
export default Marionette.CollectionView.extend({ | |
tagName: 'ul', | |
childView: TrashItemView | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment