Live data from Hacker News

Flutter 2

developers.googleblog.com

681–690 of 780 posts

Re: Flutter 2

#681

Earlier quoted context omitted.

Let me try: > Flutter 2 supports web now! > We've re-written GPay in Flutter 2! > We're dropping support for using GPay on the web...

That doesn't follow. There's any number of reasons the web app would be shut down, usage statistics being the most likely.

[deleted]

Re: Flutter 2

#682

Interesting how Flutter has evolved from a AR/VR YC company to building cross-platform developer tools at Google. Anyone know the story behind that? https://techcrunch.com/2012/03/26/flutter-app-webcam-y-combi...

I think that's just coincidental naming, the Flutter mobile framework was founded by Eric Seidel, the Flutter AR company was founded by Navneet Dalal and Mehul Nariyawala.

Interesting. I wondered why flutterapp.com (the AR/VR app) redirected to flutter.dev (the UI framework)... It led me to believe it was the same team. Apparently not. Thanks.

Re: Flutter 2

#683

Earlier quoted context omitted.

The accessibility is a bigger concern, but flutterfolio.com also A) lags on my work machine when tabbing through fields B) doesn't handle HDPI screens well (the entire interface looks blurry) C) keeps fields visually indicated as selected even when I click outside of the browser (if I start typing, is it going to go into the field or not?) D) has a separate touch mode? Touch doesn't just work? Looked up another of th…

[Flutter Eng. Dir. here] I really appreciate the feedback. We clearly have more work to do on the Web side of Flutter. Unlike the Mobile side which has shipped 100,000s of apps, the Web side may be up to like 1000. :) So many more issues to address as we work closely with more users to get their apps into production. If you'd like to track progress on any of these, I'd encourage you (or anyone else reading) to please…

My question is, if there is "more work to do on the Web", why is Flutter Web considered stable?

Re: Flutter 2

#684

Earlier quoted context omitted.

Thanks. Not related to Flutter but Google in general: I recently hit a hard-to-reproduce bug with Jetpack's LiveData for which there's already an open issue created by a third-party developer. I don't recall but it had been open since 2018 with no updates whatsoever from Google engineers on its progress. And therein lies a frustrating problem for engineers not working at Google but using Google tech. There is simply…

Hmm, LiveData is pretty straightforward class, over the years I think I memorized its implementation. I'm curious what's the issue is?

The bug is, on ocassion, while executing a query, LiveData would hit EACCESS trying to open the table (?): https://issuetracker.google.com/issues/170228126

It had to do with their Invalidation tracker (a table, I believe, which is a living log of ordered updates that need to be delivered to observers).

Re: Flutter 2

#685

I'm currently 5 months into developing a mobile app for a startup with flutter and my experience so far is very underwhelming. Flutter as a framework is not the worst but far from best, it's very OO while trying to use reacts vdom model which just wants to be functional. The biggest limitation of the platform is Dart - it's a horrible language that should have died once TS and ES6 became mature enough. And I've used…

Sorry but you don't know what you are talking about, try to use Dart as Dart, not as what you think Dart is... You have a mind block.

Re: Flutter 2

#686
post #536

Earlier quoted context omitted.

I'm not commenting on any other platforms, but I maintain a few C/WebAssembly libraries and they work exactly as expected without being unreasonably large. C-in-JS has been viable for a number of years now.

I realise it works, I just don’t think it’s really useful for what was asked for, a way to write common cross-platform business logic for a platform-specific UI. Unless there are some great new tools I’m not aware of, C on WebAssembly seems about the same as C on Android. You can compile stuff just fine, and run it, but actually connecting it up to any substantial UI written in JS/Java is going to be incredibly tedio…

The interaction between C and Javascript offered by Emscripten is a lot better than JNI on Android. I wish the Android NDK would steal a few ideas from Emscripten, but all the Android teams at Google don't seem to be able to look outside the nice comfy bubble they've created for themselves.

With Emscripten, you can embed Javascript source code directly into the C code and then call the embedded JS function from the C side as well as C functions from inside Javascript.

E.g. JS embedded in C code:

https://github.com/floooh/sokol/blob/4c56a2ee15d81cac91b738b...

...called from C:

https://github.com/floooh/sokol/blob/4c56a2ee15d81cac91b738b...

...and a C function:

https://github.com/floooh/sokol/blob/4c56a2ee15d81cac91b738b...

...called from a JS function embedded in the C code:

https://github.com/floooh/sokol/blob/4c56a2ee15d81cac91b738b...

Re: Flutter 2

#687

Earlier quoted context omitted.

Are you a native mobile developer? I am (was I'm moving to ML/AI/Data engineering) and I don't think flutter is in any way easier or nicer than the native toolchains for mobile. Both Swift and Kotlin are better languages than Dart IMO, the IDE and tooling is far superior for both also. Flutter is faster but once to deploy a substandard quality of app for sure but matching the quality of a native app? That takes just…

If you had to pick a multiplatform solution (for whatever reason) which one would you pick? I've been exploring this space a bit, and it's really hard to form an opinion on this.

If if a CRUD frontend for data, just go with mobile Web.

If doing games, Unity.

If I require some native access, Xamarin.

Finally, using C++ in a MVVM approach with native Views for anything else.

Those answers are for personal projects, at work we just do mobile Web, and with Chrome and Chrome Edge teams pushing the agenda of Web APIs =~ ChromeOS, we get to do most of the stuff we care about.

Re: Flutter 2

#688

Earlier quoted context omitted.

Could any Android dev veterans chime in and comment on JetPack? This is the first time I'm hearing about it and I'm not sure I like it. It looks like a weird blend of HTML, CSS and JavaScript event handlers and I'm starting to wonder: Why not use web technologies from the get-go then and make use of the lessons learnt there? This reminds me, I'm getting the impression that with every new UI framework that gets releas…

> Could any Android dev veterans chime in and comment on JetPack? Small nit but Jetpack is the name of the entire suite of libraries that Google offers for Android. The thing formally known as "support lib", a name that stopped making sense when it had random useful stuff not just compat stuff. You're talking about Compose here (or Jetpack Compose).

Oh right, I meant Compose. Thanks!

Re: Flutter 2

#689

Earlier quoted context omitted.

> crappy tech What kind of an argument is this? Not wanting to learn all those things for multiple languages is valid. But "it would take a while" doesn't tell you anything about whether a language is crappy. The odds are pretty close to 50:50 that the language you already know is the crappier one.

Here are some benchmarks: https://benchmarksgame-team.pages.debian.net/benchmarksgame/... The Dart implementation seems much slower than the NodeJs implementation and it doesn’t bring anything new to the table? It added null safety today. Anyone that knows if it has any feature beyond for example what Ocaml has?

To give context, the implementations for the same problem are completely different, e.g. javascript versions uses worker thrreads on 4 cores for most of the examples. To compare actual performance first similar approaches should be used.

Re: Flutter 2

#690
post #524

Earlier quoted context omitted.

I'm aware of things like the LLVM based C to JS compilers, but they're not really viable for anything non-trivial. emscripten/WebAssembly is pretty viable.

Well, if “viable” means “doable but really fiddly”. C/C++ is fine on iOS (at least when interoperating with Obj-C, Swift is trickier). C/C++ is “doable but really fiddly” on Android, same as web. There’s a compiler toolchain but not much IDE support, and you have to do all the JNI marshaling yourself. So C/C++ is only barely usable for common cross-platform code, and yet it’s the best option . What other language are…

> but in practice they don’t interoperate well and they can’t easily be used everywhere.

...and yet, it's still much better than replicating the same code in different languages just to support different platforms.

The idea that a platform dictates the language to be used for creating applications on that platform has always been ridiculous, just because it was the status quo on the web for a bit over a decade doesn't mean it's a good idea that should be copied :/

Post reply on HN