grunt build - Error: [$injector:modulerr] Failed to instantiate module

328 views
Skip to first unread message

Anurag Phadke

unread,
Sep 5, 2014, 8:20:17 PM9/5/14
to ang...@googlegroups.com
Hi,
I am building an app using AngularJS and it works without any issues via "grunt serve".
I deployed it to Apache by using "grunt build" and it gave the following error:
Error: [$injector:modulerr] Failed to instantiate module setcatApp due to: [$injector:nomod] Module 'setcatApp' is not available!
You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
http://errors.angularjs.org/1.2.16/$injector/nomod?p0=setcatApp minErr/<@http://localhost:8888/bower_components/angular/angular.js:78:5 module/<@http://localhost:8888/bower_components/angular/angular.js:1613:1 ensure@http://localhost:8888/bower_components/angular/angular.js:1535:5


Gruntfile.js here http://pastebin.com/S8AQujQf

Any idea what I am doing wrong and how to fix it?

-anurag

dinesh kumar

unread,
Sep 6, 2014, 4:43:57 AM9/6/14
to ang...@googlegroups.com
hi anurag,

i think u missed to include the js file or part of js which declares the "setcatApp".so check whether the setcatApp modules is included after the grunt task.

Thanks
Dinesh kumar.L

Anurag

unread,
Sep 6, 2014, 10:51:44 AM9/6/14
to ang...@googlegroups.com
Hey Dinesh,
The jshint section includes all the js file's that are needed for setcatApp to work.. see:
<%= config.dist %>/scripts/{,*/}*.js

Also, index.html in the dist/ folder contains <script src=scripts/15dd66f0.vendor.js> which ends up including app.js, controllers.js etc..

any other ideas?



--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to angular+u...@googlegroups.com.
To post to this group, send email to ang...@googlegroups.com.
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.



--
Twitter: @anuragphadke (https://twitter.com/#!/anuragphadke)
Reply all
Reply to author
Forward
0 new messages