1
とangularjsでUNPR不明プロバイダ私は次のように.run
機能を追加しました:私はそれをuglifyとき
coursesApp.run(['$rootScope'], function ($rootScope) {
$rootScope.slugLinkCompany = function(item, link) {
if (item) {
var makeSlug = item.name.toLowerCase().replace(/[^\w ]+/g,'').replace(/ +/g,'-');
return item.name ? [link, makeSlug, item.id].join('/') : null;
}
};
$rootScope.slugLinkCourse = function(item, link) {
if (item) {
var makeSlug = item.title.toLowerCase().replace(/[^\w ]+/g,'').replace(/ +/g,'-');
return item.title ? [link, makeSlug, item.id].join('/') : null;
}
};
$rootScope.slugLinkCategory = function(item, link) {
if (item) {
var makeSlug = item.name.toLowerCase().replace(/[^\w ]+/g,'').replace(/ +/g,'-');
return item.name ? [link, makeSlug, item.id].join('/') : null;
}
};
});
は残念ながら、私はエラー以下に遭遇しました。
Error: $injector:unpr
Unknown Provider
私が見逃しているものを教えてください。ありがとう。