marcelo.delta
marcelo.delta

Reputation: 3082

Meteor for mobile application using phonegap

Can one use meteor to build mobile applications ?

The application in phonegap data synchronization?

Upvotes: 13

Views: 4864

Answers (3)

Justin
Justin

Reputation: 225

As of Meteor 0.9.2, support for building mobile apps in Meteor, for both iOS and Android! Now with just a few new Meteor commands you can add PhoneGap / Cordova packages to your app...

Check out Meteors blog post about it: https://www.meteor.com/blog/2014/09/15/meteor-092-iOS-Android-mobile-apps-phonegap-cordova

Upvotes: 2

andrewreedy
andrewreedy

Reputation: 26

I just published a new package that fixes the issues with the methods mentioned in jadewang's post and Alan Blout's blog. Installation and setup are really straight forward. Check the readme.


Overview

Cordova Loader's goal is to make using Meteor with Cordova as easy as using Meteor itself. The compiler interprets the provided Cordova project directory and compiles the assets into minified, platform-specific JavaScript files that are placed in the Meteor /public directory. When the client loads, it automatically pulls in the platform-specific file for that device. The Cordova API can be used from Meteor the same as it is from vanilla JS apps. Enjoy!

Cordova Loader


Comparison with methods described here

  • Lazy Loading (cordova-phonegap): Hard to manage all of the Cordova dependencies / Unfinished / Outdated
  • Hijack (meteor-rider): Slow initial load / Can't use appcache / Issues with plugins.
  • iFrame (meteor-cordova): iFrames generally are a pain including slow performance in native apps, glitchy scrolling, and having to wrap Cordova
  • Cordova Loader:
    • Manages assets for you
    • Fast loading
    • Compatible with appcache
    • Compatible with Cordova plugins
    • No need for wrapper around Cordova
    • Minifies platform specific bundles
    • Automatically lazy loads platform specific bundles in client
    • Watches Cordova project plugin directory for changes

Upvotes: 1

jadewang
jadewang

Reputation: 347

In addition to Morten Henriksen's Meteor-Cordova approach mentioned above (as mentioned in comments), you should also take a look at Kasper Souren's meteor-phonegap, and Abigail Watson's Cordova-phonegap package.

Alan Blount has written a nice blog post (from late August, 2013) summarizing and assessing the various approaches:

Meteor + Phonegap/cordova (roundup – Fall 2013)

Last but not least, there's Tom Coleman's Devshop talk, "How to get your Meteor app into the App Store," which is viewable on the Meteor YouTube channel.

Upvotes: 9

Related Questions