Answer the question
In order to leave comments, you need to log in
How to display View MarionetteJS?
There is a static view
define([
'backbone.marionette',
'hbs!templates/_layouts/_aside'
],
function (Marionette, AsideView) {
'use strict';
return Backbone.Marionette.ItemView.extend({
tagName: 'nav',
id: 'main-nav',
template: AsideView,
});
});
require([
'backbone.marionette',
'domReady',
'hbs!templates/index',
'modules/statistics',
'views/item/aside-view',
'scripts/scroller',
'scripts/app',
],
function (Marionette, domReady, template, Statistics, AsideView, Scroller, App) {
document.body.innerHTML = template(template);
domReady(function () {
// Download Scroller
Scroller.initialize();
// jQuery events
$('body').on('click', function(e) {
e.preventDefault();
$('#device-btn').closest('.filter-row').find('.search-container-c').toggleClass('db',
$(e.target).is('#device-btn, .filter-icon, #search-dev, .search-li, .search-container-c .input-row')
);
});
$('.detect-change').on('click', function() {
$('.desc-change').removeClass('dr');
$('.detect-change').removeClass('active');
$( this ).addClass('active');
$( this ).next().addClass('dr');
});
});
App.start();
});
new AsideView();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question