我想了解如何使用ui路由器視圖。這是我到目前爲止有:如何使angular-ui-router模板接受兩個視圖?
var rootSubjectsSubjectAdminWordsWord = {
name: 'r.s.s.a.w.w',
template: '<div ui-view ></div>',
url: '/:wordId',
};
var rootSubjectsSubjectAdminWordsWordDelete = {
name: 'r.s.s.a.w.w.delete',
templateProvider: ['$templateCache', ($templateCache) => {
return $templateCache.get('/app/admin/word/word.html');
}],
url: '/delete',
};
/app/admin/word/word.html
<div>
<ng-include src="'/app/admin/word/wordData.html'"></ng-include>
<ng-include src="'/app/admin/word/wordForms.html'"></ng-include>
</div>
我想要做的是去除需要具有word.html。
有沒有一種方法可以使模板'<div ui-view ></div>'
以某種方式命名視圖來接受兩個HTML 文件?
看到這個https://github.com/angular-ui/ui-router/wiki/Multiple-Named-Views –