const taskServiceModule = angular.module('taskServiceModule');
class taskService {
constructor ($scope) {
console.log($scope)
}
}
taskService.$inject = ['$scope'];
taskServiceModule.service('tasksService', taskService);
export default taskServiceModule;
const app = angular.module(`app`, [taskServiceModule.name]);
我收到错误,为什么?谁能解释一下?
错误:[$ injector:unpr]未知提供者:$ scopeProvider< - $ scope< - tasksService