Jigglins
Jigglins are little bits of code that make you shake-shake-shake, shake you booty. Oh yeah, and they also add functionality to all JiggyApps. When you create a Jigglin, you create an API that all other Jiggy developers can use!
For example, we have created a Jigglin that exposes parts of UIKit to JavaScript. This lets you create applications that look like all other native applications on the iPhone, but in JavaScript. We used a collection of Jigglins to create Jiggy itself.
Get the goods
If you want to get straight to it, download the Jigglin SDK and go for it. If not, hang around for some details.
What do I need?
You will need to have a fairly up-to-date development environment; a toolchain and all that good stuff. All of our Jigglins are written in Objective-C, so you'll need to know a bit of that too. Finally, you should be able to get around the iPhone or iPod Touch - to copy files and do some of that command line stuff we love. All set?
So what do I do?
We will soon have extensive documentation explaining the whole process. For now, we'll just talk a bit about the example Jigglin included in the Jigglin SDK.
Once you have the SDK all unzipped and ready, you will need to set an environment variable pointing to your iPhone image. So, you will need to set the HEAVENLY environment variable like this:
export HEAVENLY=/Users/Bubba/Documents/heavenly
Assuming that your name is Bubba and that you have arm-apple-darwin-g++ in your path, you should now be able to go the SDK's iPhone/Example directory and run make. If all goes well, you will end up with a new library called jiggy.Process. Copy it to your iPhone's /usr/lib/ directory.
You just created a new Jigglin and are ready to test it. On your iPhone, start Jiggy and on your computer point your browser at it. Create a new application and call it whatever you want. Edit its main.js file and paste into it the contents of main.js included in the SDK's Example directory. Save it.
Open up a terminal window, SSH into your iPhone and go to the directory where your new Application is. Once there, just type ./jiggy. You should see your application logging some information it obtained by using the “Process” Jigglin you just created.
In theory, you could distribute your new Jigglin and everyone writing a JiggyApp would now have access to its functionality.
So, that's it for now - a really quick example. But, I promise we will document all of this to make it easier for everyone. If you have questions, problems or want to discuss this stuff, head on over to our Google group.