What are the steps to convert a Grails project into an PhoneGap iOS app?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

What are the steps to convert a Grails project into an PhoneGap iOS app?

vanessa
I need to integrate an existing Grails project with PhoneGap (Cordova). The Grails project is already working with jQuery Mobile for a mobile web version but now we need to access the phone camera capabilities. I believe PhoneGap is the best option but I couldn't find any instructions to set it up with Grails.

Thanks in advance!
Reply | Threaded
Open this post in threaded view
|

Re: What are the steps to convert a Grails project into an PhoneGap iOS app?

bobbywarner
PhoneGap is a framework for creating native mobile apps.  PhoneGap initializes a custom "WebView" on the device to run the code for you with extensions to access to native features.

So, you wouldn't use PhoneGap "with" Grails (or any web framework).  Instead, you build a PhoneGap app (https://build.phonegap.com) and deploy it to app stores (public or private).  The native apps then access REST services hosted somewhere for data.  The PhoneGap code is only HTML5, CSS3 and JavaScript running on the mobile device.  This is different than a normal Grails mobile website running in a mobile browser.

This is actually exactly what I have been working on recently for a project at my company.  I built JSON services with Grails hosted in our data-center and then published native mobile apps with PhoneGap (and jQueryMobile) to our internal app-store (both iOS and Android) that access those Grails services for data.  Hope that helps!  Let me know if you have any additional questions.


Thanks,
Bobby
Reply | Threaded
Open this post in threaded view
|

Re: What are the steps to convert a Grails project into an PhoneGap iOS app?

Sebastien Blanc
And just for info, I'm currently working on a plugin that will scaffolds an "independent" client (pure html5/CSS/js) calling via Rest your grails app. Next step is to create a plugin that wraps the phonegap build platform  APIs , so you can scaffold&build in one step !


Envoyé de mon iPhone

Le Mar 12, 2012 à 20:27, bobbywarner <[hidden email]> a écrit :

> PhoneGap is a framework for creating native mobile apps.  PhoneGap
> initializes a custom "WebView" on the device to run the code for you with
> extensions to access to native features.
>
> So, you wouldn't use PhoneGap "with" Grails (or any web framework).
> Instead, you build a PhoneGap app (https://build.phonegap.com) and deploy it
> to app stores (public or private).  The native apps then access REST
> services hosted somewhere for data.  The PhoneGap code is only HTML5, CSS3
> and JavaScript running on the mobile device.  This is different than a
> normal Grails mobile website running in a mobile browser.
>
> This is actually exactly what I have been working on recently for a project
> at my company.  I built JSON services with Grails hosted in our data-center
> and then published native mobile apps with PhoneGap (and jQueryMobile) to
> our internal app-store (both iOS and Android) that access those Grails
> services for data.  Hope that helps!  Let me know if you have any additional
> questions.
>
>
> Thanks,
> Bobby
>
> --
> View this message in context: http://grails.1312388.n4.nabble.com/What-are-the-steps-to-convert-a-Grails-project-into-an-PhoneGap-iOS-app-tp4466139p4467098.html
> Sent from the Grails - user mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: What are the steps to convert a Grails project into an PhoneGap iOS app?

bobbywarner
Sebastien,
Cool, looking forward to it!


Thanks,
Bobby
Reply | Threaded
Open this post in threaded view
|

Re: What are the steps to convert a Grails project into an PhoneGap iOS app?

vanessa
In reply to this post by bobbywarner
Thanks for your quick response.  I understand your approach and it definitely makes sense.  We are actually developing the web services for other clients so it possible to take that route.

The reason why I thought is was possible was because I found a small tutorial (http://manijshrestha.wordpress.com/2011/09/10/building-a-native-kind-of-android-app-using-grails-html-5-css-javescript-hosted-on-cloudfoundry/) on how to do it for an Android app where the grails app is hosted in cloud foundry and then in the android activity class they load the grails app with the  URL. However, I've never developed iOS or android apps so I couldn't tell if it was a valid approach.


 
Reply | Threaded
Open this post in threaded view
|

Re: What are the steps to convert a Grails project into an PhoneGap iOS app?

Jon Polaski
I found this post while googling a similar curiosity.

Check out https://github.com/3musket33rs/phonegapbuild
I was very impressed that I was able to build a native android app in less than an hour from an existing Grails application.

Check out this sample project too:
https://github.com/3musket33rs/ThreeCircles

Kudos to 3musket33rs