I was too busy to write any blog posts last week, but this more than makes up for it…
Stop the press!
My new Cordova / PhoneGap plugin allows you to use the real native iOS transitions without ever leaving your web view!
I’ve turned page transitions around (poor pun, I know).
This is so good, for the first time on my blog, it demands a video demo. Yes, that really is a Cordova web view with a single HTML page.
Down to business
If you’re a Cordova / PhoneGap developer, I’m sure you’re already desperate to get started, so I’ll cut to the chase.
The source code is available on Github.
Assuming you’re using Cordova 3.x and the CLI, installation is as simple as using the
cordova plugin add command:
nativetransitions object to your root automatically when you build.
Flip page transition, with support for flipping left or right:
Curl page transition, with support for flipping curling up or down:
A simple fade page transition:
Here’s an example of how I suggest you use the plugin in your code, so that you get a realistic transition:
If you’d like to add more transitions (possibly custom transitions of your own) please pull request. If you’d like something in particular, let me know and I’ll see if I can implement it for you.
This is pretty flippin’ amazing stuff (OK, I’ll stop now).