
Flutter: UI platform designed for ambient computing - plexicle
https://developers.googleblog.com/2019/12/flutter-ui-ambient-computing.html
======
losvedir
Wow, talk about burying the lede. I'm not sure how I feel about Google's so-
called "ambient computing" idea that they were all about at this year's Google
I/O, but Flutter being championed for desktop and web are huge! Does this mean
the end of Electron, finally? They say it runs on macOS, I hope they get to
Windows and Linux soon.

I built a little Android/iOS app in Flutter and it was a real delight. I
didn't especially like Dart at first, but it was easy enough to pick up and
then got out of the way more or less. I'd love to be able to easily run an app
like that on the web. I know Dart's original vision was to replace JS but it
seems they backed off that a bit. But it sounds like it's back on the menu!

I don't know if this changes anything exactly, in terms of what Flutter can do
right now. I think web/desktop have always sort of been there. But what's new
for me is this perspective that they intend to support other devices beyond
mobile. I wasn't really sure about that before, since it seemed _mostly_
tailored to just iOS/Android when I was working with it.

~~~
skybrian
I don't know how well they're supporting desktop and web UI idioms yet, but it
looks like you can try out Flutter on the web using DartPad:

[https://medium.com/dartlang/a-brand-new-dartpad-dev-with-
flu...](https://medium.com/dartlang/a-brand-new-dartpad-dev-with-flutter-
support-16fe6027784)

~~~
pests
Flutter already offically supports web and is a compilable target by default.
You don't need dartpad. It is still on beta.

[https://flutter.dev/web](https://flutter.dev/web)

------
yesimahuman
Bizarre reading the vision for this "ambient computing" platform given that
the web platform has already been doing that for years and you could imagine
the Chrome team using nearly identical terms to describe what their mission
is.

~~~
IshKebab
Sure, but the web is never going to be a great platform for apps on mobile or
embedded devices.

~~~
yesimahuman
You'd be surprised how many popular and widely used mobile apps run a
significant portion of their experience with web tech. Depending on who you
ask it _is_ a great platform for mobile apps (not that it can't be improved of
course!)

------
DonHopkins
31 years late, Google attempts to re-brand "Ubiquitous Computing" (aka "Calm
Technology") as "Ambient Computing". At least it sounds more mellow, less
intrusive, unwelcome, penetrative, and phallic than the other attempt at
rebranding UbiComp as "Pervasive Computing" in order to sell it to the
military.

[https://en.wikipedia.org/wiki/Ubiquitous_computing](https://en.wikipedia.org/wiki/Ubiquitous_computing)

[https://en.wikipedia.org/wiki/Calm_technology](https://en.wikipedia.org/wiki/Calm_technology)

[https://www.researchgate.net/post/What_is_differents_between...](https://www.researchgate.net/post/What_is_differents_between_Pervasive_Computing_and_Ubiquitous_Computing)

[https://internetofthingsagenda.techtarget.com/definition/per...](https://internetofthingsagenda.techtarget.com/definition/pervasive-
computing-ubiquitous-computing)

>The term pervasive computing followed in the late 1990s, largely popularized
by the creation of IBM's pervasive computing division. Though synonymous
today, Professor Friedemann Mattern of the Swiss Federal Institute of
Technology in Zurich noted in a 2004 paper that:

>Weiser saw the term 'ubiquitous computing' in a more academic and idealistic
sense as an unobtrusive, human-centric technology vision that will not be
realized for many years, yet [the] industry has coined the term 'pervasive
computing' with a slightly different slant. Though this also relates to
pervasive and omnipresent information processing, its primary goal is to use
this information processing in the near future in the fields of electronic
commerce and web-based business processes. In this pragmatic variation --
where wireless communication plays an important role alongside various mobile
devices such as smartphones and PDAs -- ubiquitous computing is already
gaining a foothold in practice.

You say pervasive, I say perversive. Let's call the whole thing off.

------
erokar
What are people's impression of Dart as a language, compared to e.g.
Typescript? Reviews so far seems lackluster. Does Dart have anything that sets
it apart from JS, like immutable data structures out of the box? How's the
support for functional programming, e.g. first order functions, closures,
higher order functions like map, filter, reduce, etc?

How advanced is the typing system, are we talking Java level or significantly
more powerful?

~~~
IshKebab
I've used both recently, deciding between them. Dart is better.

* Typescript is _much_ more popular, and integrates with other Javascript things better. There are way more libraries available for Typescript.

* Typescript has proper support for non-null types, whereas in Dart everything is nullable (though they are fixing it, as announced here).

* Typescript has pretty nice support for anonymous sum types (i.e. `number | string`).

However:

* Typescript doesn't actually fix any of the insanity of Javascript - it just _describes_ it. So you can still do insane things like using `var` or `==`. In Dart all of that nonsense has been removed.

* Typescript has `interface` and `class` which is needlessly confusing (it has no choice because Javascript).

* It's _way_ too easy to give up on typing in Typescript. It has a setting "no implicit `any`" but it doesn't seem to be comprehensive. You can do still stuff like just omitting the return type of functions and then they instantly lose all type information. In Dart you have to explicitly opt in to `dynamic`.

* Because types are added to Javascript libraries (via DefinitelyTyped), there's nothing that really checks that they are correct and very often they are just _wrong_. It's pretty annoying to fix when that happens and even harder to know what the correct fix is because obviously the underlying Javascript library has no types! You basically have to ask the authors what they meant.

* A lot of libraries aren't fully typed. For example Vue has very minimal typing - lots of things are just strings. As a concrete example, AngularDart gives you compile errors if the types in your HTML template are incorrect. With Vue they are runtime errors.

* The Dart VSCode extension is literally amazing. It gives you perfect errors and completion and it does it instantly. Nothing else I've used comes close.

When I first started using Typescript I was kind of under the impression that
it was a better language built on top of Javascript. That's not really the
case - it's still Javascript, it's just a slightly less insane way of using
Javascript.

Dart, on the other hand _is_ a better language.

~~~
mikewhy
> You can do still stuff like just omitting the return type of functions and
> then they instantly lose all type information.

That's not the case:
[http://www.typescriptlang.org/play/#code/GYVwdgxgLglg9mABFAp...](http://www.typescriptlang.org/play/#code/GYVwdgxgLglg9mABFApgZygCgJSIN4CwAUIogE4pQhlIAsATMQL7HGoY4B0UcAqgA78UZAMIBDNChxA)

~~~
IshKebab
I stand corrected. Must have been thinking of something else.

------
arkanciscan
Scanned the whole article, still don't know what "ambient computing" is. I
suppose they mean writing apps that run on the little microphones they want us
to put all over our houses. Seems like I remember there being a platform that
was built in the '90s to run on any device. What was it called..

~~~
coldtea
> _Scanned the whole article, still don 't know what "ambient computing" is._

As TFA says:

"In this emerging world, the focus starts to move away from any individual
device towards an environment where your services and software are available
wherever you need them. We call this ambient computing".

In other words, going from devices as siloes you use one at a time, each with
each own apps, accounts, data, and so on, into using a plethora of devices
that play together, can run appropriate versions of the same apps, give you
access to your data from wherever you are, switch your workflow from one to
another, and so on.

So like multi-platform apps + cloud storage + what Apple calls "Handoff /
Continuity" or MS calls "Timeline" \+ IoT...

------
whytaka
This is what I understood from all the hubbub around Fuchsia with Flutter
powering the interfaces.

~~~
kyrra
It's not called out in this blog post, but back at Google I/O earlier this
year, they did say Fuchsia is powering the Nest Hub and Nest Hub Max. So those
smart displays Google is making are Fuchsia + Flutter.

~~~
jasonvorhe
Actually, both Nest Hubs run on the Chromecast-platform, not on Fuchsia[1].
However their UI is actually made with Flutter[2]. However, both devices (as
Sherlock and Astro respectively) exist in the Fuchsia repo and so it's safe to
assume that they're developing Fuchsia on them and since Flutter is multi-
platform they can replace the OS underneath via software update, if they chose
to.

[1]
[https://www.reddit.com/r/Fuchsia/comments/blyutb/the_nest_hu...](https://www.reddit.com/r/Fuchsia/comments/blyutb/the_nest_hub_devices_are_built_on_fluttercould/?utm_medium=android_app&utm_source=share)
(See top comment)

[2]
[https://twitter.com/timsneath/status/1125868510645669888?s=2...](https://twitter.com/timsneath/status/1125868510645669888?s=20)

~~~
kyrra
Ahh, good to know, thanks!

------
g5becks
It would be really nice if Google would get something going for dart on the
server-side. I personally would make the switch to using dart full time for my
side projects if I got the same benefits as I do with using node / react.

------
pjmlp
I guess the folks doing Jetpack Compose better hurry up getting a stable
version out.

------
soneca
Not sure if it is counter-intuitive, but I was deciding between React Native
and Flutter for a project and this announcement nudged me to decide on React
Native.

I am pretty sure I just want my app to run on Android, iOS, and web. If
Flutter's vision is making it possible to also design to TVs, smartwatches,
thermostats, doorbells, fridges, etc it means that there will be trade-offs,
added complexity, overhead, design choices to support that _" ambient
computing"_ vision.

I don't want any of that, and it is good to know that in advance. RN it is.

~~~
christocracy
I’m a professional plugin developer. I make plugins for Cordova, React Native
and Flutter. Flutter is my favorite.

You should do a hello world at least.

~~~
kd22
Is building plugins faster/easier than building apps (using Flutter)? Looking
to learn flutter so wondering if I should build a plugin or app when going
beyond hello world.

~~~
christocracy
Build an app. There are many things in the plugin api that you don’t interact
with in the app. The plugin api is the bridge between the front-end and native
iOS / Android apis.

------
ble52
Am I the only one who sees all these Electrons, React Natives, Flutters, etc.
as mostly middle-management-pleasing technologies made for crunching cookie-
cutter apps with the least amount of outsourced developers as possible?

Whenever I see Slack, Spotify, VS Code, or any other "universal" app, it
always strikes me as a completely out of place it looks and behaves, no matter
what OS it's running on. Yes, it's relatively easy to make a multiplatform app
with these technologies, ticking all the boxes specified by bean-counters, but
in the process it usually completely sacrifices all the little details,
integrations, patterns, etc. that make platform-specific apps such a pleasure
to use. If you're used to apps behaving in a predictable manner, e.g. having
similar shortcuts, similar icons having the same meaning (and other way round
- similar actions having the same icon), then e.g. seeing a Material Design on
macOS is just weird and looks completely out-of-place, not mentioning event UX
aspects.

I know it's hard to quantify this in an Excel spreadsheet, but in my opinion
following interface guidelines of the target platform and properly using its
native technologies makes for a much better user experience (I'm talking here
about the basic meaning of this phrase). For example, just look at Google Docs
app for iPad - for sure it's written using some Google's weird "universal"
technology, but every time Apple announces new iOS (now iPadOS) features, like
split screen, multiple windows, etc. it taks Google months to provide support
for them. At the same time, developers that follow Apple's guidelines and
recommendation, they usually get these features in their apps "for free" or
with relatively small amounts of work required.

I'm simplifying the whole situation here, of course, but I think trend of
making all apps in Flutter et al. might be good for some people, but end-users
are usually not one of them.

~~~
LocalPCGuy
Using Flutter has been extremely helpful for us in a startup environment,
getting apps built for both iOS and Android in half the time (or less)
compared to doing both. Our team has plenty of native mobile experience and
has built separate native apps that mirror functionality in the past.

Flutter was so much more efficient, it actually lives up to the promise of
write-once, build to multiple platforms.

As for design, we have a very custom design and in Flutter you are in no way
locked into Material design.

