Electron(Atom-shell) for Dart

1,164 views
Skip to first unread message

Suguru Inatomi

unread,
May 17, 2015, 9:33:31 PM5/17/15
to mi...@dartlang.org
Electron(old name "Atom-shell") is an awesome approach to package an web application with the browser to make native desktop apps.
By the way, Dart has Dartium. Something like Electron for Dart have been planned in the team?

Lex Berezhny

unread,
May 17, 2015, 9:42:50 PM5/17/15
to misc
There is Sky but for now that's mostly intended for mobile devices.


Sky is an experimental, high-performance UI framework for mobile apps. Sky helps you create apps with beautiful user interfaces and high-quality interactive design that run smoothly at 120 Hz.

Sky consists of two components:

  1. The Sky engine. The engine is the core of the system. Written in C++, the engine provides the muscle of the Sky system. The engine provides several primitives, including a soft real-time scheduler and a hierarchial, retained-mode graphics system, that let you build high-quality apps.

  2. The Sky framework. The framework makes it easy to build apps using Sky by providing familiar user interface widgets, such as buttons, infinite lists, and animations, on top of the engine using Dart. These extensible components follow a functional programming style inspired by React.

We're still iterating on Sky heavily, which means the framework and underlying engine are both likely to change in incompatible ways several times, but if you're interested in trying out the system, this document can help you get started.

Suguru Inatomi

unread,
May 17, 2015, 11:30:02 PM5/17/15
to mi...@dartlang.org
Wow, it means Sky will target mobiles and desktop both?  

ravi teja

unread,
May 18, 2015, 3:11:36 AM5/18/15
to mi...@dartlang.org
It would be great to have it on desktop, on all platforms. But currently they seem to focus only on Android.

On 18 May 2015 at 05:30, Suguru Inatomi <laco...@gmail.com> wrote:
Wow, it means Sky will target mobiles and desktop both?  

--
For other discussions, see https://groups.google.com/a/dartlang.org/
 
For HOWTO questions, visit http://stackoverflow.com/tags/dart
 
To file a bug report or feature request, go to http://www.dartbug.com/new

To unsubscribe from this group and stop receiving emails from it, send an email to misc+uns...@dartlang.org.

Günter Zöchbauer

unread,
May 18, 2015, 4:36:39 AM5/18/15
to mi...@dartlang.org
Where did you read "desktop"?

Suguru Inatomi

unread,
May 18, 2015, 5:21:37 AM5/18/15
to mi...@dartlang.org
There is Sky but for now that's mostly intended for mobile devices.

I thought this means it may support desktop platforms in the future.

2015年5月18日月曜日 17時36分39秒 UTC+9 Günter Zöchbauer:

Lex Berezhny

unread,
May 18, 2015, 7:13:06 AM5/18/15
to misc
On Mon, May 18, 2015 at 5:21 AM, Suguru Inatomi <laco...@gmail.com> wrote:
There is Sky but for now that's mostly intended for mobile devices.

I thought this means it may support desktop platforms in the future.

Ironically, the story is actually kind of backwards: Sky is built on-top of mojo which is made from Chromium parts which as we know runs on "desktop".

I think that by virtue of Sky having chromium roots and the eventual goal of having it run on iOS will require enough platform abstraction that it shouldn't be a stretch to say that it is guaranteed to also run on "desktop".

Also, when we say "desktop" what do we mean? Windows, Mac and Linux aren't exactly "the same desktop platform". Besides, we're getting closer and closer to full convergence: Ubuntu now runs mobile, Windows 10 runs mobile, Chrome OS lets you run Android apps, etc.

The more interesting thing for me actually is when will Sky apps run in plain old browsers? I asked something along these lines on #mojo IRC a while ago and the response I got was that it 1) should be possible and 2) they hope the community will do it. And if you look in the depths of Sky source you'll see that for the most part it's the familiar querySelector, element creation and shadow dom APIs from HTML5. These APIs will probably continue to change but the fact that Sky is based on Chrome suggests that porting Sky apps to plain Chrome probably shouldn't be that difficult.

Furthermore, my impression is that Sky is basically a modern web browser - if Google were to invent a web browser today without worrying about backwards compatibility this is what it would look like. Of course if Google describes the project this way you can imagine the uproar, so instead Sky is just a mobile UI platform for Dart (more benign this way) :-) Saving the internet from terabytes upon terabytes of "Sky will never be the next browser"... kind of like when Google announced Dart as the next JavaScript and all the haters came out of the wood work.

Everyone made a big deal about Dart VM not being put into Chrome but the reality is that Google appears to have changed course onto even bigger plans. If you can't convince Firefox/Safari/IE to add Dart then just start an entirely new platform - makes sense to me.

Of course keep in mind that all of these projects are experimental and speculative. The only stuff that's certain is Dart as a language (regardless of VM/implementation) and dart2js (because Google Ads depends on it)...

At least that's what I think :-)

 - lex

Günter Zöchbauer

unread,
May 18, 2015, 7:42:38 AM5/18/15
to mi...@dartlang.org
Sounds interesting.

Grant Jason

unread,
May 19, 2015, 6:27:54 AM5/19/15
to mi...@dartlang.org
Thanks for your views and context Lex.


On Monday, May 18, 2015 at 1:13:06 PM UTC+2, Lex Berezhny wrote:

Alex Tatumizer

unread,
May 19, 2015, 11:56:11 AM5/19/15
to mi...@dartlang.org
> Sky helps you create apps with beautiful user interfaces and high-quality interactive design that run smoothly at 120 Hz.

> Sky is built on-top of mojo which is made from Chromium parts which as we know runs on "desktop"

I think these 2 statements slightly contradict each other. From chromium parts? Which parts? By any chance, isn't it DOM, CSS, HTML etc? So in the end, it will look exactly as it does in the browser, but will *work* faster. That's fine, but "beautiful" is not  the first word that comes to mind when WRT aesthetic value of the result. My bet is: after spending extraordinary effort to design and implement this new arrangement of old parts, the things on the screen will look as underwhelming as they are now.

Bob Nystrom

unread,
May 19, 2015, 12:28:05 PM5/19/15
to General Dart Discussion

On Tue, May 19, 2015 at 8:56 AM, Alex Tatumizer <tatu...@gmail.com> wrote:
By any chance, isn't it DOM, CSS, HTML etc?

Nope!

You can look at Dart as a clean-slate design that tries to be familiar to users coming from JS. Sky does the same thing for the DOM, CSS, and HTML. They're trying to keep what's good about those languages, but not what's bad.

Cheers!

- bob

Lex Berezhny

unread,
May 19, 2015, 12:54:58 PM5/19/15
to misc
Just as V8 made it possible to build browser based applications that people didn't think where possible before, I think Sky is aiming for the same sort of major shift in UI development. This argument is supported by the emphasis in the Dart Summit Sky presentation on how fast Sky can go through the render loop and how much room you have to do stuff in each frame.

I think Sky will bring a new level of interaction and animation to UIs that wasn't practical before on commodity hardware.

Justin Fagnani

unread,
May 19, 2015, 1:32:11 PM5/19/15
to General Dart Discussion
Sky goes further: it's exposing what underlies those languages, such as paint, text layout, networking, and then gets rid of the languages entirely. AFAIK, DOM, CSS and HTML are all gone. There's a render tree, line layout, per-node styling without selecting or cascading, and i/o. If you want CSS and HTML like things, you have to build them yourself, in Dart.


 

Cheers!

- bob

Alex Tatumizer

unread,
May 19, 2015, 1:38:22 PM5/19/15
to mi...@dartlang.org
> Sky goes further: it's exposing what underlies those languages, such as paint, text layout, networking,
Very intriguing! Is there any human readable documentation available? API samples? Discussion of concepts, etc?

Filipe Morgado

unread,
May 19, 2015, 3:03:15 PM5/19/15
to mi...@dartlang.org
On Tuesday, 19 May 2015 18:38:22 UTC+1, Alex Tatumizer wrote:
Very intriguing! Is there any human readable documentation available? API samples? Discussion of concepts, etc?

I'd like to know as well :)
Although this repo seems to answer a few questions, regarding API and samples.

I understood that Mojo is an optimized native UI (stripped-down DOM elements, as Justin hinted) in its own thread (view) which will send/get events/updates to/from the "model/controller services" in other threads, written in other languages, through a common message-passing interface.

Mojo-sdk are the bindings (or interface API/implementation) for a lot of languages, C, C++, Java, Python, Go, Dart, etc.

Sky is Mojo with an embed Dart VM for the service threads, and Sky-sdk is the API to use from Dart.

Is it something along those lines?

Is Sky meant to be Dart-only or can we expect other languages, such as Java for a smoother Android integration? 

Justin Fagnani

unread,
May 19, 2015, 3:31:12 PM5/19/15
to General Dart Discussion
On Tue, May 19, 2015 at 12:03 PM, Filipe Morgado <pix...@gmail.com> wrote:
On Tuesday, 19 May 2015 18:38:22 UTC+1, Alex Tatumizer wrote:
Very intriguing! Is there any human readable documentation available? API samples? Discussion of concepts, etc?

I'd like to know as well :)
Although this repo seems to answer a few questions, regarding API and samples.

I understood that Mojo is an optimized native UI

Mojo is mostly an IPC system between services, as I understand it.
 
(stripped-down DOM elements, as Justin hinted)

Mojo has no DOM, never did that I know of. Sky is removing or has removed its DOM.
 
in its own thread (view) which will send/get events/updates to/from the "model/controller services" in other threads, written in other languages, through a common message-passing interface.

Mojo-sdk are the bindings (or interface API/implementation) for a lot of languages, C, C++, Java, Python, Go, Dart, etc.

Sky is Mojo with an embed Dart VM for the service threads, and Sky-sdk is the API to use from Dart.

Is it something along those lines?

Is Sky meant to be Dart-only or can we expect other languages, such as Java for a smoother Android integration? 

--

Alex Tatumizer

unread,
May 19, 2015, 3:48:42 PM5/19/15
to mi...@dartlang.org
The discussion so far reminds this old parable: http://en.wikipedia.org/wiki/Blind_men_and_an_elephant

Filipe Morgado

unread,
May 19, 2015, 3:59:02 PM5/19/15
to mi...@dartlang.org
On Tuesday, 19 May 2015 20:48:42 UTC+1, Alex Tatumizer wrote:
The discussion so far reminds this old parable: http://en.wikipedia.org/wiki/Blind_men_and_an_elephant

+1 :D 

Don Olmstead

unread,
May 19, 2015, 4:10:35 PM5/19/15
to mi...@dartlang.org
They're removing it? That sucks. Think it would be great to have something where you can target web or mobile native easily. Sky seemed like it was going to support web components.

--

Mark H

unread,
May 19, 2015, 5:14:43 PM5/19/15
to mi...@dartlang.org
Yes, that's what I was hoping for - web and mobile/desktop all using the same web components based UI and Dart code.

Alex Tatumizer

unread,
May 19, 2015, 5:15:57 PM5/19/15
to mi...@dartlang.org
The most impressive part of sky framework so far is the list of authors
https://github.com/domokit/sky_sdk/blob/master/packages/sky/AUTHORS
Something epic is afoot here.


kc

unread,
May 24, 2015, 9:25:06 AM5/24/15
to mi...@dartlang.org
On Monday, May 18, 2015 at 12:13:06 PM UTC+1, Lex Berezhny wrote:
 
Everyone made a big deal about Dart VM not being put into Chrome but the reality is that Google appears to have changed course onto even bigger plans. If you can't convince Firefox/Safari/IE to add Dart then just start an entirely new platform - makes sense to me.

Of course keep in mind that all of these projects are experimental and speculative. The only stuff that's certain is Dart as a language (regardless of VM/implementation) and dart2js (because Google Ads depends on it)...

At least that's what I think :-)

 - lex

This is my take  as well.

Dart is a basically a high performance structured scripting language. If Mojo/Sky goes from experiment to product developers will give Dart a second chance. And the more DSL-ish/declarative the language is - thus allowing the avoidance of HTML/CSS etc - the more likely dev's (like Alex) will bite. So for v2.0 I think Dart should risk some backward incompatibility because there's a bigger prize. Keep the 1.x web oriented dev's happy though.

K.

Steven Roose

unread,
Jan 7, 2016, 2:46:33 PM1/7/16
to Dart Misc
No one actually answered this question apart from pointing out Sky (which is now Flutter), but that's an entirely different thing.

Considering the Dart VM already runs on desktops, it must be able to built an Electron-like platform on it, just like Electron builds on NodeJS.

I guess the Chrome team at Google fears that that will draw attention for Web-based desktop apps away from Chrome Apps.. However Chrome Apps lack a lot of basic IO capabilities that Electron/NodeJS/dart:io can provide.

So, can someone from the team let us know if this is ever discussed or considered? Or should be all just use Electron with node_io.dart and compiled JS?


Thanks
Steven

Bob Nystrom

unread,
Jan 7, 2016, 3:13:40 PM1/7/16
to General Dart Discussion

On Thu, Jan 7, 2016 at 11:46 AM, Steven Roose <steve...@gmail.com> wrote:
So, can someone from the team let us know if this is ever discussed or considered?

I can't recall it coming up.

That doesn't mean it's a bad idea, just that's it not a product we, the Dart team, have put effort into. We're more a language team than a platform team, so most of our focus is on making Dart work well for platforms that are already successful (the web) or that other teams are driving forward (Flutter).

If some other team appeared and started cranking on an Electron-like shell for Dart, I'm sure we'd be happy to support them and help them succeed, but it's not something I think we'd be likely to take the initiative on. (With the usual caveat that I'm just an engineer on the team so don't consider any of this a promise, binding agreement, prediction, official team position, etc. :) )

Cheers!

– bob


Benjamin Strauß

unread,
Jan 8, 2016, 5:13:18 PM1/8/16
to Dart Misc
I think at this point it would make more sense to "just" write the desktop backends for flutter. The framework was written with platform abstractions from the very beginning, so i guess it would not be that hard. I'm sure the flutter team would help if someone from the community would be like to do that. Unfortunately I'm not familiar with C++. :)

Steven Roose

unread,
Jan 8, 2016, 9:40:12 PM1/8/16
to mi...@dartlang.org
@Benjamin
You are probably right. However, Flutter works entirely different. electron (aka node-webkit) allows you to use web technologies to build desktop apps.

Currently at least, Flutter uses a widget-based API for doing UI.

--
For other discussions, see https://groups.google.com/a/dartlang.org/
 
For HOWTO questions, visit http://stackoverflow.com/tags/dart
 
To file a bug report or feature request, go to http://www.dartbug.com/new
---
You received this message because you are subscribed to a topic in the Google Groups "Dart Misc" group.
To unsubscribe from this topic, visit https://groups.google.com/a/dartlang.org/d/topic/misc/9NuTuBrGeZI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to misc+uns...@dartlang.org.

Benjamin Strauß

unread,
Jan 9, 2016, 12:34:38 PM1/9/16
to Dart Misc
I think not relying on the web stack and all of its quirks and baggage is a good thing. :)
Reply all
Reply to author
Forward
0 new messages