Helping Transition from JavaScript to iOS (examples in JavaScript and Objective-C)