我写了个组件,但是在引用到网页的时候出现了[$compile:tpload] Failed to load template这个问题,具体原因会有哪些呀?有什么比较好的解决方法的?
111111
这是组件模板
(function () {
angular.module('ui.component.worksComment',[])
.directive('uiComponentWorksComment',worksComment)
worksComment.$inject = [];
function worksComment(){
return {
restrict: 'EA',
transclude: true,
scope:{
Comment:"=",
},
templateUrl:"components/uiComponents/worksComment/worksComment.tpl.html",
};
};
}());
组件的JS文件
1111111
页面引用
angular.module('worksDetailContent',[
'ui.component.worksComment'
])
然后我也在相应的app.js文件里配置过了
Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
小伙看你根骨奇佳,潜力无限,来学PHP伐。