ng-app="app" cannot resolve symbol app

I'm not finding much on how to resolve this.

I'm running IntelliJ IDEA  Build #IU-183.4588.61

 

I've got an AngularJS site with no warning or errors except one.

The warning is Cannot resolve symbol 'app'

 

In my index.html, I've got ng-app="app" and I've got a module defined as 'app'

 

I'm not sure what I need to do to resolve this issue.  I wouldn't mind turning off the inspection, but I cannot find that option either.

 

4 comments

What does your module definition look like? Is the other stuff (custom directives, controllers, etc.) properly resolved?

1

Module definition looks like this:

angular.module( 'app', [
'ngRoute'
])

As far as I can tell controllers and directives are resolved; no warnings anyway...

0

Works fine for me using similar syntax:

Please try invalidating caches (File | Invalidate caches, Invalidate and restart) - does the problem persist? If yes, please share a project that can be used to recreate it

0

Solved the issue by marking the folder containing index.html as Resource Root.

 

Thanks for your help

1

Please sign in to leave a comment.