Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Flutter seems like the killer app that could revive Dart. In comparison:

Javascript

For mobile with React: no AOT compile. Relies on loading the entire JS VM which adds startup time and can require bundling a large library on Android. Cannot easily author customized components that render at native speeds.

C#

For mobile with Xamarin: No hot reload. Dart having its origin as a JS interpreted language had the foundations to be both dynamic and AOT. C# might not ever achieve this?

Kotlin, Java, Swift, Objective C:

Not cross platform.

C++:

Is cross platform. No hot reload. Very unfriendly to modern development and fast iteration.

I don't actively work in mobile. I just like following developments in language technologies, so correct me if I'm wrong.



Depending on how far you want to stretch it Kotlin is cross-platform-ish.

You can write Kotlin that compiles to both JVM and JS, and KotlinNative claims to be able to then also compile that to native.

It's hard to do, and there's a major lack of abstractions even within the standard library, but technically possible. I could easily see a future where your business logic is portable kotlin and then you have platform-specific UI layers.


Yea but you can't develop for iOS using Kotlin. That's a big advantage for React Native/Electron/Flutter and JS world as a whole.


Yes, you can. Kotlin/Native targets iOS: https://kotlinlang.org/docs/reference/native-overview.html

And if you're going to consider JS as supporting iOS then KotlinJS works on iOS, too.

So Kotlin is doubly runnable on iOS as either native code or JS.


How have you not used Xamarin?

Hot reload is supported, C# has a REPL nowadays and there are workbooks, Swift storyboard style.

There are Java AOT compilers for iOS, at least three that I can remember of.

C++ with Qt/QML is very productive for mobile development.


re Xamarin:

Only reloading your XAML or CSS is supported. With Dart, you can reload all your code, in the same way JS developers have had hot reload for ages now. I'm not sure if C# will be able to support this. This really leverages Dart's roots in being interpreted, not compiled.

https://docs.microsoft.com/en-us/xamarin/xamarin-forms/xaml/...

  What changes does Live Reload redeploy?
  
  Live Reload only applies changes made to XAML or CSS. If you make changes to a C# file, a recompile will be required. Support for reloading C# is planned for a future release.


Yep, and as you quote "Support for reloading C# is planned for a future release."

On the standard .NET Framework, edit-and-continue has been a thing during the last couple of years.

I rather have the maturity of .NET eco-system, than the uncertainty of the young Dart one.


The main negative with Flutter on iOS is that your app ends up looking like an awful Google app instead of something native.


There's a Cupertino theme.


Yeah, and in Flutter it's actually impossible to use system native UI libraries like navigation etc. So if you would like to build a simple app using each platform's native components, you'd have to build them yourself. (And update them as iOS/Android updates their UI).




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: