这里是我的角度代码:
angular.module('TM', [])
.controller('protocolCtrl', function(){
this.categoryText = 'Now looking at the protocol part'
})
.controller('categoryCtrl', function(){
this.protocolText = 'Now looking at the category part'
})
.directive('modalDirective', function(){
return {
restrict: 'E',
scope: {
list: '='
},
template: ['<div id="modal" class="modal fade" role="dialog">',
'<div class="modal-dialog">',
'</div>',
'</div>'].join('')
}
});
如果我直接在HTML文件中使用HTML模板,它显示,而不是其他。
的错误是希望真的不起眼,但是任何帮助表示赞赏。
你有没有在仅仅使用用户界面,引导模式采取看看吗? https://angular-ui.github.io/bootstrap/它会为你做这一切。 – mikeswright49
你的角JS不会在你的小提琴中加载。 404 –
工作正常..只需要修理你的小提琴。改为使用此链接.. https://ajax.googleapis.com/ajax/libs/angularjs/1.4.3/angular.min.js这里是一个演示.. https://jsfiddle.net/DTcHh/10131/ –