javascript - AngularJS Component wont allow Injection into Lifestyle Hook -
im using angular 1.5 , building application in component structure. unknown provider
error when i'm attempting inject $canactivate
hook (which shouldn't happen) heres code:
angular.module("app") .component("index", { templateurl:"/modules/index-app.component.html", $canactivate:function($timeout) { <-- creates error return $timeout(function() { console.log('timeout fired') }, 2000); }, controller:function($timeout, $location, authcookie) { // set 'this' var model = }, controlleras:"model", });
im running angular 1.5.3 if makes difference? if don't inject hook runs fine. i'd love know people's thoughts :)
Comments
Post a Comment