ngCordova apprate ionic-v1


#1

Hi all!
I am trying to inject ng-cordova apprate to my app.
I am following this instruction.

http://ngcordova.com/docs/plugins/appRate/

but I have that kind of error messages:

## Error: $injector:modulerr
## Module Error

Failed to instantiate module starter due to:
ReferenceError: AppRate is not defined
    at Object.setCustomLocale (http://10.21.1.115:8100/js/ng-cordova.min.js:7:3789)
    at exports.default (http://10.21.1.115:8100/js/app.js:7:30349)
    at Object.invoke (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:75:295)
    at d (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:73:234)
    at http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:73:358
    at q (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:41:355)
    at g (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:73:135)
    at eb (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:77:164)
    at c (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:54:463)
    at yc (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:55:274)
    at de (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:54:83)
    at http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:344:121
    at HTMLDocument.b (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:220:389)
    at Pf (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:70:477)
    at HTMLDocument.d (http://10.21.1.115:8100/lib/ionic/js/ionic.bundle.min.js:70:424

My code:


## service.js

export default function CordovaReady() {
    return ['$window', function ($window) {
        document.addEventListener("deviceready", function () {
            console.log('************** cordova ready **************');
        }, false);

        return {
            CordovaReady: CordovaReady
        };
    }];
}

## run.js

export function onReady($ionicPlatform, $window, CordovaReady) {
	$ionicPlatform.ready(function() {
		console.log('ionicPlatform');
		// Hide the accessory bar by default (remove this to show the accessory bar above the keyboard
		// for form inputs)
		if ($window.cordova && $window.cordova.plugins && $window.cordova.plugins.Keyboard) {
			cordova.plugins.Keyboard.hideKeyboardAccessoryBar(true);
			cordova.plugins.Keyboard.disableScroll(true);

		}
		if ($window.Keyboard) {
			$window.Keyboard.shrinkView(true);
		}
		if ($window.StatusBar) {
			// org.apache.cordova.statusbar required
			StatusBar.styleDefault();
		}
	});
}

## config.js

export default ['$ionicCloudProvider', '$httpProvider', '$stateProvider', '$urlRouterProvider', '$ionicConfigProvider', '$cordovaAppRateProvider', function ($ionicCloudProvider, $httpProvider, $stateProvider, $urlRouterProvider, $ionicConfigProvider, $cordovaAppRateProvider){
	
	$ionicConfigProvider.views.maxCache(0);
	$ionicConfigProvider.scrolling.jsScrolling(true);

	var prefs = {
		language: 'de',
		appName: 'bonbon',
		iosURL: '1129241722',
		androidURL: 'market://details?=ch.siroop.app&hl=de'
	};

	var strings = {
		title: 'bonbon'
	};

	$cordovaAppRateProvider.setCustomLocale(strings);
	$cordovaAppRateProvider.setPreferences(prefs);

Somebody has an idea, why i get these error messages?
Thanks in advnace!