user1155141 user1155141 - 2 months ago 10
AngularJS Question

Add second item to module in angular

I'm trying to add ngStorage to a module that already has functionality. I am really new to angular so forgive me for my incorrect usage of terms. I thought I had ngStorage added right into the module but the code breaks when I add it.

Origional code:



'use strict';
angular.module('mobsocial.climbs', [
'ionic',
])





Added with ngStogare:



'use strict';
angular.module('mobsocial.climbs', ['ngStorage',
'ionic',
])





What am I doing wrong? Thanks

Answer
'use strict';
angular.module('mobsocial.climbs', ['ngStorage','ionic'])

you are using extra comma in your code. Also make sure you have included ng-storage library file in index