Jean Lebrument
Jean Lebrument

Reputation: 5169

Interaction between Dart/Objective-C and Dart/Java

I read a really interesting article about how create cross-plateform app : http://www.skyscanner.net/blogs/developing-mobile-cross-platform-library-part-3-javascript

But I would prefer use Dart instead of Javascript, and I was wondering if it's possible to interact between Dart/Objc and Dart/Java (Android), in the exact same way that is showed in the article (run a Javascript VM to execute the javascript code).

Thanks

Upvotes: 2

Views: 545

Answers (2)

Lex Berezhny
Lex Berezhny

Reputation: 522

iOS does not allow 3rd party VMs to be included with your app. The only VM you have access to is the JavaScript VM that is bundled standard with iOS. Even Google Chrome on iOS is crippled in this way (they cannot include v8 on iOS).

Upvotes: 1

GoogleFailedMe
GoogleFailedMe

Reputation: 125

You can code it in Dart and use dart2js to output JS code then put that JS code in PhoneGap or Cocoonjs to get it on Android/IOS.

The article seems to show how its done with JavaScript. I am sure its possible to code a Dart mobile cross-platform library but it hasnt been done yet.

Upvotes: 1

Related Questions