Cordova & Ionic on ios - Device plugin not working [SOLVED]

Hello Ionic community!

I have a problem that has been preventing me from doing anything userfull for like three or four days.
The thing is that I get a strange error, may be related to Cordova, it’s about the deviceready event, and their implementations with $ionicFramework.ready(...) do not work either.

So far, I have been looking for an answer but all the answers that worked for someone, didn’t work for me.
Common things like ionic plugin add x and all that are tested and not working.

Here I let you the stackoverflow post:

Thaks for your attention!

Solution

I have found a solution, seems that ionic hooks add ios and not doing chmod -R 777 * helped, plus deleting the ./platforms/ folder and adding it again.

The last thing (delete/re-add) has been tried over and over, didn’t work until I did the last two things.