mirror of
https://github.com/bendtherules/slide_in_demo.git
synced 2026-08-20 00:34:42 +00:00
Used backbone + marionetee
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
|
||||
function init_marionette () {
|
||||
var Mn = Backbone.Marionette;
|
||||
var Bb = Backbone;
|
||||
|
||||
var RootView = Mn.View.extend({
|
||||
template:'#template'
|
||||
});
|
||||
|
||||
var App = Mn.Application.extend({
|
||||
region: '#slide',
|
||||
|
||||
onStart : function(app,options) {
|
||||
this.showView(new RootView(options));
|
||||
}
|
||||
});
|
||||
|
||||
var myApp = new App();
|
||||
var tmp_model = new Bb.Model(data)
|
||||
myApp.start({model: tmp_model });
|
||||
}
|
||||
|
||||
init_marionette();
|
||||
Reference in New Issue
Block a user