javascript - How to map view and viewmodel SPA -
i follwing course single page application pluralsight. http://www.pluralsight.com/training/courses/tableofcontents/single-page-apps-jumpstart
if guy saw example solution in course there 2 views , 2 viewmodels. need based on example it's add treeview control , top of page (using kendo ui treeview , dialog jquery ui control). question it's: how can add treeview control new view in single page application?
function boot() { router.mapnav('home'); router.mapnav('details'); log('aquavet loaded!', null, true); return router.activate('home'); }
in shell class of application can see view/viewmodles mapped.
and after in navigation view these used:
<div class="btn-group" data-bind="foreach: router.visibleroutes"> <a data-bind="css: { active: isactive }, attr: { href: hash }, text: name" class="btn btn-info" href="#"></a> </div>
what want add new view wich shoul not in navigation menu.. how ca distinct between view in navigation menu , views places in other places (like treeview) ?
in course see there nav view not in main menu. nav view pure html view composed shell view. point can embed views wherever want, using compose binding durandal.
Comments
Post a Comment