0

I my project I came into an issue about the package of angular-cookies.

I have download the package and place it in my project. And as usually, in index.html, I add a script tag:

<script src="vendor/angular-cookies/angular-cookies.min.js" charset="UTF-8"></script>

But when the pages loaded I got an error message:

Uncaught TypeError: c.module(...).info is not a function at angular-cookies.min.js:7

in the package, it uses angular.module.info but it is not regarded as a function?

So what is the reason for this issue? Is it because version issue? Any help

Chris Bao
  • 2,418
  • 8
  • 35
  • 62

2 Answers2

0

I had the same problem with a recent bower update I've done. I don't know if the angular 1.6.3 is stable so I went to https://code.angularjs.org/latest/ and I saw that is 1.5.8 angular version which is used.

So to resolve it, I added these versions in my bower.json :

"dependencies": {
"angular-cookies": "1.5.8",
},

"resolutions": {
"angular": "1.5.8"
}

flosej
  • 74
  • 4
0

You should install particular dependecies according to angular.You can achieve it by using bower install like this:

bower install angular-cookies@1.5.8

bower install angular@1.5.7
Shubham Verma
  • 8,783
  • 6
  • 58
  • 79