angularjs - Error: [ng:areq] Argument 'ProjectsController' is not a function, got undefined -


Why are my project controllers undefined? I get this error message from my browser console

You can see that to see this plunker yourself.

  'strict use'; Angular .module ( 'projectplanner', [ 'ui.router']) .config (function ($ stateProvider, $ urlRouterProvider) {$ urlRouterProvider.otherwise ( '/ projects'); $ stateProvider .state ( 'projects', {url '/ projects' views: { "menu": {template '! Start your projects'}, 'content': {templateUrl: "projects.html", controller 'ProjectsController'}}}) Kstate ( 'Projectskselected', {url: '/: ProjectId'}) Kstate ( 'Projectskselectedkdates', {url:' / Date /: date, views: {menu: {templateUrl: 'menu. html'}, 'content': {templateUrl: 'dateplanner.html', controller: 'DateplannerController'}}})}); 'Strict use'; Angular Modules ('Project Planner') Controller ('Projects Controller', Function ($ Scope, $ State) {});  

You did not include your js

  & Lt; Script src = "app.js" & gt; & Lt; / Script & gt; & Lt; Script src = "ProjectsController.js" & gt; & Lt; / Script & gt;  

correct


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -