Я использовал Gulp для минимизации всех моих js-файлов. После того, как уменьшенная я получил сообщение об ошибке, как следующее:
[$injector:unpr] Unknown provider: eProvider <- e <- makeErrorsDirective.
Я имел Выборочная директиву в моем файле контроллера.
var myhubdashboardControllers = angular.module('vpdashboardmodule', []);
.directive('mhDashboard', function ($http, authService, apiService) {
return {
restrict: 'EA',
scope: {
name: '@',
dash: '@',
report: '@',
disname: '@',
disdesc: '@',
distot: '@'
},
templateUrl: 'views/dashboard/dashboard-direc.html',
link: function (scope, element, attr) {
scope.linkChk = scope.name;
switch (scope.linkChk) {
case 'Shipped This Week':
scope.url = 'erp/JobShipmentList/PostCpsVwShipmentCount';
scope.shipstatus = "Departure";
scope.period = "ThisWeek";
scope.basicfilter = "Open";
scope.linkName = "Shipments";
scope.linkDesc = "Shipped This Week";
break;
}) };
Это код, используемый в моем приложении.
Возможный дубликат [Уклонение от углового с помощью grunt uglify, приводящее к ошибке js] (http://stackoverflow.com/questions/22866183/angularjs-minification-using-grunt-uglify-resulting-in-js-error) – Webbies