News for hackers. Stuff that matters.
Re:Framework 7 – Building native iOS apps in HTML5 by bmj on Friday March 21, 2014 @09:21AM (#7442049)
As someone who has used several cross-platform frameworks (Titanium, Cordova/PhoneGap, investigating Xamarin), I have a question about going "full native": how do you handle shared core code? Our app has an engine that drives the business logic, and the cross-platform frameworks have been useful because we don't have to deal with modifying the core codebase for different platforms [0]. Is it possible to create platform-agnostic libraries that can be shared?

[0] Despite the many claims of "cross-platform UIs," we have many cases in our UI layer of doing different things on different platforms.

Re:Framework 7 – Building native iOS apps in HTML5 by tluyben2 on Friday March 21, 2014 @09:52AM (#7442282)
Xamarin is great for sharing code. You just rewrite the GUI layer per platform. It's great, cannot really say it any differently.
Re:Framework 7 – Building native iOS apps in HTML5 by CmonDev on Friday March 21, 2014 @11:43AM (#7442928)
And that GUI layer could be just Views in the end, since it seems you can even re-use ViewModels/Controllers.
Re:Framework 7 – Building native iOS apps in HTML5 by mattgreenrocks on Friday March 21, 2014 @09:56AM (#7442306)
This is the exact use case for Hexagonal/Clean Architecture: http://blog.groupbuddies.com/posts/20-clean-architecture

It is contentious on HN, but I implore you to draw your own conclusions.

Re:Framework 7 – Building native iOS apps in HTML5 by untog on Friday March 21, 2014 @09:31AM (#7442135)
If have read before that C++ can be used to share logic. An interesting development with iOS7 is that it has a JavaScript runtime of some sort (I don't know the details) - perhaps it will be possible to use JS for cross-platform code.
Re:Framework 7 – Building native iOS apps in HTML5 by notjosh on Friday March 21, 2014 @10:50AM (#7442608)
You're thinking of JavaScriptCore. It allows Objective-C objects to be used inside of JavaScript (and vice versa).

It's actually a pretty cool technology. I gave a talk about it this month at Berlin CocoaHeads, and I'm gonna put some blog posts together about it soon!

Re:Framework 7 – Building native iOS apps in HTML5 by mattgreenrocks on Friday March 21, 2014 @01:46PM (#7443601)
I presume the JSCore runtime bridges objects back and forth? Very cool!