4 ms·
How To: Native iOS apps in Javascript
- st3fan 16y agoThe title of this HN posting is very misleading. The title of the original article is: Create NATIVE-LOOKING iPhone/iPad applications from HTML, CSS and JavaScript
- johnbender 16y agoapologies, got to typing just a bit too fast.
- daleharvey 16y agoYeh the title is a bit measleading, but the content is good, I have found mobile web development to still be fairly immature and hard to find information about, so this helps.
- yoda_sl 16y agoYou can definitely write some pure JS apps on iOS and bypass once for all the AppStore review process but you have to keep in mind that the JS runtime does not have yet access to all the API provided by the OS underneath. Here a a few things & there are many more that you will not be able to access from JS: - camera/video - photo library - address book - embedding a smooth map view: you can get google maps to appear but it will not be as smooth as the native MapKit control - all the goodness of CoreAnimation but the CSS animation on iOS made tremendous progress in each release - speed: even if with iOS 4.3 and the Nitro engine JS is faster, the compiled Objective-C / C / C++ will most likely be faster - re-use various existing runtime library (Facebook Connect/ DropBox / ...) Please do nit think that I don't believe in pure web app on iOS or other device. Some app can fit well the model abd make perfect sense to do as such, but I will strongly recommend that before comitting to a 100% web app, check that all the features you want to achieve are doable through JavaScript/CSS
- ericz 16y agoAlso, webkit's multitouch gesture support is rather terrible compared to the iOS SDK's. Rotation and zoom with multi-touch worked, but was obviously not native to anyone who used iOS devices on a regular basis. Expect jumpiness, rotation about incorrect axis and similar hair pulling bugs.
- ericz 16y agoBad title but the article is incredibly important for anyone building a mobile website targeted at iOS. The included techniques are inexplicably difficult to find, and even in Apple's own documentation.
- DanielRibeiro 16y agoAlthough, why you'd want to subject yourself to the app store approval process when you don't have to is beyond me Maybe because this way you can use frameworks like Phonegap and Titanium Appcelerator to enable access to things accelerometer, compass and other native features.
- jpallen 16y agoNice article, thanks. Is there anyway to have a smoother 'install' process rather than just asking the user to bookmark your page?
- catshirt 16y agothose who were intrigued but deceived by the title should check out appcelerator [1] [1] http://www.appcelerator.com/ http://www.appcelerator.com/