Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Phonegap?

Programming for mobile devices is surely an important topic, altough I wonder how many complete beginners are going to take this on. Then, how many beginning programmers are actually going to do it the hard way, i.e. C, Java etc.? As a php/CSS/JS developer (lots of us out there who haven't touched apps yet, but want to), I'm very much interested in app development with Phonegap/Cordova. Are you going to have something on that?

7 Answers

Ben Jakuben
STAFF
Ben Jakuben
Treehouse Teacher

Very nice apps have been built with tools like PhoneGap, and it certainly makes sense to use cross-platform tools for a number of reasons. Usually, though, you will achieve the best results using native tools and languages. You also need to be aware that with cross-platform apps, you often can't follow the recommended (and expected) user interface guidelines for each platform, which can frustrate users. For example, iOS and Android have different strategies for in-app navigation, and porting iOS navigation to an Android app can really alienate users and cause bad reviews.

But, I think Randy raised some good points about how web technologies can be used effectively, and I think they will get more and more viable in the future. But for now (and the next few years, at least), you just can't beat native with platform-tailored user experiences.

Also, while we don't cover PhoneGap or anything like it, we have talked about featuring it in a workshop or something, and feedback like this helps us know what you the members want, so thanks!

Zach Malter
Zach Malter
11,483 Points

Has anything changed here? It is now 2018 and a lot has changed in terms of the functionality you are able to accomplish within Phonegap Cordova.

It's interesting because Facebook abandoned their HTML5 apps and went native. There are probably a ton of reasons we'll never know about but that decision probably speaks to a lot of typical situations. If you can build a native app (and afford to maintain different codebases) then it's a better strategy IMHO.

Randy Hoyt
STAFF
Randy Hoyt
Treehouse Guest Teacher

Regarding the Facebook app, I would recommend reading the article "The Making of Fastbook". The authors discuss in depth a lot of the things that the Facebook app did wrong and developed a new version on Sencha Touch that improves it quite a bit.

The article is great to show that getting HTML5 to work in the context of a native wrapper is hard. You probably don't want to write HTML/CSS/JS yourself and then wrap it Phonegap for anything much more than static content with links. Instead, you probably want to use a framework like Sencha Touch that will handle a lot of interactivity and performance/scaling issues.

hi all , does anyone know when treehouse will come up with the new phonegap tutorial . badly waiting for one .

Ben Jakuben
Ben Jakuben
Treehouse Teacher

Hi Kalyani,

There isn't anything for PhoneGap currently on our roadmap, but thanks for the feedback that it would be useful. I don't know exactly how this fits into our current setup. I think it would be best suited as a workshop as we recommend working on native apps or responsive sites.

Of course native is better, no doubt about it. Facebook is a good example. They have unlimited resources and can hire any developer in the world to write any app they imagine. So they most probably get it done in the best possible way. For them. I wish I had a client like that. And the time to learn a couple of new programming languages. But learning a new language is neither necessary nor do I have the resources. As you say: "If you can ..." What I can do, and what every other html/php/JS developer can do, is learn to use something like phonegap. And Treehouse can help us learn ... Anyway, it would also be useful to know exactly what the advantages of one way is over the other. Probably native apps run faster. Probably phonegap does not support all features of all phones. But surely it is much cheaper and faster to use phonegap if the app is supposed to run on many different devices. That's a big advantage, if the performance of the app is not essential.

Thanks Randy. I had heard of Sencha Touch before, thanks for the reminder. I do need a bit more than static links. Will check it out. The Fastbook article is an interesting read, indeed.

samiff
samiff
31,206 Points

Hopefully the performance issues continue to improve. I'd also like to point out two related topics you might be interested in:

Device APIs Working Group

Firefox OS