Wednesday, July 15, 2015

Are PhoneGap and Cordova the same?

No, they are not!.

Maybe you can think that I'm totally crazy and wrong, right?
All the time we can read things like "Phonegap is using Cordoba as its core" and bla, bla, bla. And..., yes, it's right.

But today I got very confused (wasting a lot of time) when I tried to add the Android platform to the project in two different computers: in a Mac (where we previously had created the iOS platform version), and in a PC, but the results were incompatible!.

My first impression was: Bahh, evidently these computers have different SO and have different Phonegap versions. As the people used to say: the more probably cause is that the Mac is more updated than the PC.

But not, the real cause was that we had generated the project on Mac using Cordoba CLI, and today I was trying to obtain "similar results" but using Phonegap CLI instead of Cordoba in the PC. The results: I got different project's files.

So, I installed both in my PC: Cordoba and PhoneGap to create the same project with each one, but surprise: they are not generating the same content!. Their file' structures are completely incompatible, at point that they do not recognize each other content as a valid project folder.

Take a look at this image:

Are you seeing the same like me? How many differences you can detect? I'm going to help you, just count the files and folders marked in yellow color.

So, my conclusion is: they have many compatibles stuff, but No, they are not the same.

You should to decide which one to use. For example, Ionic framework selected Cordoba. Me? I'm going to do the same.