Trying to run an Angular app containing this controller:
routerApp.controller('chartSettingsCtrl', ['$scope', '$timeout',
, function($scope, $timeout) { /* body omitted */ }
gives me the error:
Error: [$injector:itkn] Incorrect injection token! Expected service name as string, got undefined
What am I doing wrong?
The actual problem is that I had an extra ,
in the controller. When I changed that, it worked.
From
routerApp.controller('chartSettingsCtrl', ['$scope', '$timeout',
, function($scope, $timeout) {
To
routerApp.controller('chartSettingsCtrl', ['$scope', '$timeout',
function($scope, $timeout) {
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With