Angular-translator module 'pascalprecht.translate' not found
I am trying to add angular-translate to my angular app. I followed this simple quick start: https://angular-translate.github.io/docs/#/guide but my app won't load, resulting in the following error:
Unprepared error: [$ injector: modulerr] Failed to instantiate module myApp due to: Error: [$ injector: modulerr] Failed to instantiate module pascalprecht.translate due to: Error: [$ injector: nomod] Module 'pascalprecht. translate 'is not available! You either misspelled the name of the module, or forgot to load it. If registering the module ensures that you specify the dependencies as the second argument.
My index.html file correctly includes the angular translation, for example:
<script src="bower_components/angular-translate/angular-translate.js"></script>
What is the clue why this might be happening? I am very grateful for the help.
UPDATE
Here's part of my app.js to clarify things a bit:
var app = angular.module('myApp', [
'ngAnimate',
'ngCookies',
'ngResource',
'ngSanitize',
'ngTouch',
// 3rd party modules.
'ui.router',
'restangular',
'angular.filter',
'ui.bootstrap',
'pascalprecht.translate',
// Custom modules.
'myApp.config'
])
.
.
.
source to share
I faced the same problem, resolved it by adding below entries. Also remember to put these .js files in the correct order.
files : [
'../js/libs/angular.js',
'../libs/angular-route.js',
'../angular-translate.min.js',
'../libs/angular-translate-loader-url.js',
Hope this helps.
Best regards, Aditi.
source to share