Ask HN: Best language to share code between an Android and iOS app?
11–20 of 123 posts
Re: Ask HN: Best language to share code between an Android and iOS app?
#12Re: Ask HN: Best language to share code between an Android and iOS app?
#13Just use JavaScript. Javascriptcore is a lightweight way to execute JavaScript on iOS and you can use V8 context or duktape on Android. This way you can also update code in your app without an app store update.
Edit: Sorry for being unclear, was only referring to the updating JS on the fly and circumventing App Store part. Obviously (facepalm) ... ️
Re: Ask HN: Best language to share code between an Android and iOS app?
#14Re: Ask HN: Best language to share code between an Android and iOS app?
#15It is part of both SDKs, you have direct support for mixed mode debugging on the IDEs.
No need of extra tooling.
On Android JNI is always going to be a pain, but at least with C++ Studio gives you an hand on accessing JNI APIs.
Re: Ask HN: Best language to share code between an Android and iOS app?
#16Just use JavaScript. Javascriptcore is a lightweight way to execute JavaScript on iOS and you can use V8 context or duktape on Android. This way you can also update code in your app without an app store update.
which is not allowed on iOS ... Edit: Sorry for being unclear, was only referring to the updating JS on the fly and circumventing App Store part. Obviously (facepalm) ... ️
Re: Ask HN: Best language to share code between an Android and iOS app?
#17Re: Ask HN: Best language to share code between an Android and iOS app?
#18Just use JavaScript. Javascriptcore is a lightweight way to execute JavaScript on iOS and you can use V8 context or duktape on Android. This way you can also update code in your app without an app store update.
which is not allowed on iOS ... Edit: Sorry for being unclear, was only referring to the updating JS on the fly and circumventing App Store part. Obviously (facepalm) ... ️
Re: Ask HN: Best language to share code between an Android and iOS app?
#19Just use JavaScript. Javascriptcore is a lightweight way to execute JavaScript on iOS and you can use V8 context or duktape on Android. This way you can also update code in your app without an app store update.
which is not allowed on iOS ... Edit: Sorry for being unclear, was only referring to the updating JS on the fly and circumventing App Store part. Obviously (facepalm) ... ️
Perhaps your thinking about downloading such JS code at runtime from your servers, thus escaping Apple's control on the app, which was indeed forbidden (it is now ok as long as you don't drastically change the app)
Bundling JS in the app and running it has always been just fine.