javascript - Uncaught Error: [$injector:modulerr with angualrJs when i use routing -


this part of problem = https://jsfiddle.net/2vrz38d6/ contain js part open console see have

i confused solve error
error: $injector:modulerr module error

uncaught error: [$injector:modulerr] http://errors.angularjs.org/1.3.10/$injector/modulerr?p0=myapp&p1=error%3a%…3a9641%2fassets%2fglobal%2fplugins%2fangularjs%2fangular.min.js%3a38%3a435) 

my error happen routing in angularjs error took : my error page here

my code :

(function () {     var myapp = angular.module('myapp');       myapp.config(function ($routeprovider) {         $routeprovider             .when('/', {                 templateurl: 'views/expenses.html',                 controller: 'curriculumcontroller'             })           .otherwise({            redirectto: '/'         }); 

and controller

        myapp.controller('curriculumcontroller', ['$scope', '$rest', function ($scope, $rest) {  //some stuf here  

for script angular file : in first have

 <script src="/assets/global/plugins/angularjs/angular.min.js"></script> 

and in middle of project have file of angular apps

<script src="/scripts/ngmodel/curriculum/curriculum.js"></script> 

and after file of routing part angularjs

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0rc1/angular-route.min.js"></script> 

as people above have suggested, need include file, need make sure doing in correct order in index file. suppose trying different set of cdns wouldn't hurt either.

<script src="https://code.angularjs.org/1.3.15/angular.min.js"></script> <script src="https://code.angularjs.org/1.3.15/angular-route.min.js"></script> 

also, in route configurations, mention can otherwise:

myapp.config(function ($routeprovider) {     $routeprovider     .when('/', {         templateurl: 'views/expenses.html',         controller: 'curriculumcontroller'     })     .otherwise("/"); }); 

Comments