
Why I'm joining the Dart Team - wstrange
https://medium.com/@filiph/why-i-m-joining-the-dart-team-of-all-places-d0b9f83a3b66#.oldcuv47e
======
jondubois
I liked Dart from the beginning... It could have been a perfect replacement
for JavaScript a few years ago, but now with ES6 becoming widely available in
browsers and Node.js, I feel that some of the shine of Dart has been lost.

I think the biggest problem with Dart isn't related to the project itself - My
biggest concern is that other browser vendors didn't embrace it. Dart has not
been universally accepted by all sides, despite the massive amount of
publicity which it received over the years.

With ES6, I think that JavaScript has proved that it can adapt to change and
that it has significant staying power.

I think the Dart team made all the right moves, but, unfortunately, so did the
JS team.

The project hasn't had much luck either. There was no breakthrough. Getting
its own native VM inside Chrome would have been nice.

~~~
mariusmg
"With ES6, I think that JavaScript has proved that it can adapt to change"

JavaScript proved squat. Those changes should have been done a long time ago
and now we should have had a sane language instead of JS. Betting on JS
"evolving" is the wrong way to go.

~~~
incepted
> Betting on JS "evolving" is the wrong way to go.

Why? It __is __evolving. Slowly, but it is evolving.

Enough to cast a doubt on the viability of Dart and Typescript.

~~~
cwyers
I think Typescript is in a different boat. All valid JS is valid Typescript,
and Typescript is adding new JS features faster than browsers can. If JS ever
catches up to Typescript it'll be by becoming Typescript, basically.

------
Matthias247
I used Dart for a project 1-2 years ago and really enjoyed it. It's a well
designed language with an equally well designed standard library and already
had fabulous tooling (IDE support, package manager, debugger) back then. My
hopes were that it could really replace JS at some point of time, because I'm
not the biggest fan of JS in the ES5 incarnation. For me it was a little bit
sad to see that Dart got almost no external traction since while Go got lot's
of traction. I personally think Dart is the better language in most regards.

Since then I have worked on a few non-web projects and now got back to
building some bigger application with node, a browser frontend and typescript.
With the current revisions of typescript I don't miss much from Dart,
Typescript did a great job on building a type system that fits to Javascript
and the ecosystem (available libraries, etc.) is huge due to seamless
interoperability (export typescript as JS libraries and import all JS as
untyped typescript). Therefore for me the appeal to use Dart instead of
typescript in classical web applications is much lower then some years before.

For other applications the choice of languages is already more then abundant.
I don't think it would have been a bad move to introduce it as an Android
application language, but I don't think that will happen due to all the
existing code.

I'm interested to see what will happen in the microcontroller domain, but this
is a very slowly evolving domain where real changes happen rarly and everybody
is stuck on C despite alternatives have been available earlier. Don't see a
special appeal for raspberry PI like devices - these are more like PCs then
really embedded stuff. You can run nearly anything you want there.

------
mavdi
Dart is a great language. I tried it on day one and it has come a long way
since then. But in my experience... every time I read an article trying to
justify why something is still relevant or important in a company roadmap, it
dies a lonely death a short time after.

~~~
michaelwww
> trying to justify why something is still relevant or important in a company
> roadmap

While I know what you mean, I didn't read the article that way at all. The
author isn't a marketing type or someone high up in the company, but a
programmer making a calculation about Dart and passing on his observation to
his friends, who don't see that situation the way he does. Dart has received a
lot of bad press because some Dart engineers made the mistake of saying it
would replace JavaScript. I didn't get involved in defending JavaScript from
Dart and wrote a bunch of Dart, and I noticed I was about twice as productive.
I also learned along the way that Google was heavily invested in something
called Google Web Toolkit, a Java based system for writing web apps. I figured
Google was looking to replace that with Dart so it would always have a place,
and it looks like I was right. The code that powers the engine that brings in
17 billion dollars a year is nothing to dismiss, like many do of Dart, if in
fact they are converting GWT to Dart, and it sounds like they are.

TypeScript is one way to add safety, Dart is another. The difference in the
two approaches is discussed here by the two main authors Anders Hejlsberg and
Lars Bak respectively [1]. What I found compelling about Dart was the
elimination of "monkey patching" that Lars talks about. I was also drawn to
try TypeScript and found it a great tool as well. So does Google as they are
now using TypeScript in Angular 2.0. Microsoft and Google are working together
- never thought I'd see the day.

[1]
[https://www.youtube.com/watch?v=5AqbCQuK0gM](https://www.youtube.com/watch?v=5AqbCQuK0gM)

------
jug
I couldn't help reading the emphasized "types" in "optional types" as a yell
for the Typescript developers to come back.

But I too hope that Dart will become more successful, because let's stop
beating around the bush -- it isn't now, not relatively speaking and comparing
to the state of web development today. And this is unfortunatenly _not_
because web development hasn't been rapidly evolving the past few years.

But enough negativity. I found this part the most interesting, because today
there are already so many ways to get various non-officially sanctioned
languages onto both iOS and Android:

> Soon, you’ll be able to write Dart code for micro-processors (think
> Raspberry Pi) and — more interestingly — for micro-controllers (think
> Arduino). This means developing for really compact, really cheap, really
> low-energy devices is no longer a C/C++/asm club.

Maybe Dart can at least find an unexpected niche?

~~~
filiph
I'm the author of the article.

> I couldn't help reading the emphasized "types" in "optional types" as a yell
> for the Typescript developers to come back.

Not sure what you mean, but I definitely didn't have TypeScript in mind. I
emphasized "optional" in "optional types" in the bulletpoint where I'm talking
about "getting out of your way", and "type" in the next bulletpoint where I'm
talking about structure. It was meant to be cute but evidently I failed...
Sorry for the confusion.

~~~
bovermyer
I got your meaning.

I liked Dart enough to give a talk about it at the local Google user group a
year or so ago. Sadly, I haven't touched it since; less because I fear that
it's a dead/failed language, and more because I simply haven't found a use
case for it where a language I already know better doesn't do an acceptable
job.

------
matthewrudy
I think it's interesting that the author says: "I’m betting my career on it"

Careers in software are (hopefully) long and varied.

Committing to work for a few years on one particular technology should not
make or break your career.

As long as we're always learning and sharing our knowledge and skills, we
should all be better off.

Regardless of whether Dart ever hits the mainstream.

~~~
incepted
> I think it's interesting that the author says: "I’m betting my career on it"

Yes, the author is probably a bit junior in that field. You don't bet your
career on technologies, much less languages (especially beleaguered languages
like Dart).

You take a bet, see if it works for a few years and if it doesn't (which is
the case for 99% of languages out there), you move on to something else.

------
shadowmint
One of the things that Rust (GC free zero cost memory management), Swift (the
official iOS programming language with excellent UI libraries) and Blueprint
(easy coding for non-coders in UE4) have made crystal clear to me is that,
_if_ you choose to create a new programming language rather than using an
existing one, you need to _actually decide_ what the draw card you have is,
over other existing solutions, and stick to it.

Dart has consistently failed to be anything more interesting than slightly
better javascript that interops poorly with existing the existing javascript
ecosystem.

That is not a draw card.

Now, it seems to be trying to be 'a generally useful programming language you
can use on multiple platforms'. That's not a draw card. Just _stop_!

Please actually focus on making Dart something special, or give up on it.

There's this thing, where you make something and you get invested in it, and
it becomes to politically complicated to throw away.

I have no technical objections to Dart, it's a fairly nice language; but I
too, cannot come up with any reason to either use it, or be excited about the
future of it.

------
Yuioup
I've made this comment before. I'm wondering if there are plans to replace
Java with Dart or Go on the Android platform. This because of the continuing
threat of lawsuits from Oracle.

It's probably impossible to replace Dalvik because you need the bytcode but
maybe replacing the language might shield Google from Oracle.

~~~
pornel
It would be fantastic if Swift was adopted as the language for Android.

It's a very well-designed language (with non-nullable types and
immutability!). It's now open-source, and development model is even more open
than Android's throw-over-the-wall.

Swift's type inference and ARC makes it feel very script-like, but it supports
AOT compilation and tighter control over memory usage.

While Cocoa won't be available on Android, having a single language that's
usable on iOS, Android and server-side would be great for reusing as much as
possible.

~~~
V-2
Android already has Kotlin. It's kind of similar to Swift. You're quoting non-
nullable types, immutability, open-source, well it has it all.

~~~
voider1
How well does Kotlin perform on Android? Can you use all the native stuff? Are
there some successful apps written in Kotlin?

~~~
on_and_off
>How well does Kotlin perform on Android? Can you use all the native stuff?

Not only is Kotlin a great language, it is also a good fit for Android since
it outputs bytecode and is entirely interoperable with java. The only cost of
using Kotlin are the 6k methods that it adds to the apk. You can call all the
native Android APIs. Of course they are not idiomatic kotlin code, but you can
cope with that, especially since the Kotlin team has written some Extensions
methods in order to facilitate this process.

>Are there some successful apps written in Kotlin?

I know that Expedia uses some Kotlin for its new features (since there is full
interop, you can switch gradually). I am working alongside 12 or so other
engineers on a successful Android app. Most of us (especially the more
experimented) would like to switch to Kotlin but we get a lot of resistance
from an extremely change averse team leader (we have just convinced him to
start using EventBus and are still pushing for Dagger 2 & Rx).

This kind of move is always complex for a large team though. You need to get
everyone on board and up to speed with this new language. Even though I think
that kotlin is very easy to learn (especially for a java dev), this is still a
significant effort.

~~~
V-2
Personally I think a good way to set a foot in the door (with Kotlin) is to
use it for unit tests. Hey, unit tests aren't production code, so what's the
worst that can happen, right? Plus in many projects - sadly - tests are still
perceived as an optional thing.

And Kotlin is very well suited for tests, because it's so expressive, DSL-
friendly etc. There's also this pleasant framework:
[http://jetbrains.github.io/spek/](http://jetbrains.github.io/spek/)

If you can't convince your team (or bosses) to switch to Kotlin, start writing
unit tests in Kotlin. They can even coexist with Java ones, so I believe this
is an easy way in. And once people get to see it at work...

~~~
on_and_off
thanks, that's an interesting idea.

we already have started making more and more tests several months ago (the
code base we inherited is awfully architectured and entirely untested), I will
try to win over our test engineer with that idea.

------
dom96
It's interesting to hear that Dart was designed as a general-purpose language.
I always assumed that Dart was kind of like Coffeescript, that it was only
meant to be translated into JavaScript.

I'm curious how this fits in with Go, another programming language from
Google, which is also presumably a general-purpose language. Can anybody
compare Go and Dart?

~~~
filiph
I see Go as a systems language and I think it was designed that way (wikipedia
agrees with me here but I don't know enough about it so I'm not claiming this
to be true). AFAIK it's used mostly for server / CLI stuff, where its
concurrency model and speed shines.

~~~
danieldk
I do write a lot of Go and it fits in the Oberon/Modula-2/C family. It is a
general purpose language and the design of the language does not really make
it a system language. In fact, one could argue that many properties that
people expect of a system language (e.g. no GC) are missing.

Currently, Go is indeed popular for network services and command-line tools,
but I think that is due to it's standard library supporting those use-cases
well. But Go will surely branch out as its ecosystem matures.

------
phloxicon
I used Dart a while ago for a personal project. Language-wise, it has
dramatically improved by 'await'. My favorite part about Dart is the standard
library. I've never used a language with a better standard library.

Does anyone know how Dart will be affected by web assembly?

~~~
mraleph
> Does anyone know how Dart will be affected by web assembly?

WebAssembly right now is a suitable target only for C++ like languages. There
is a hope that in the future WebAssembly will introduce features enabling
efficient compilation of dynamic languages, but so far it's unclear when this
hope is going to materialize into something more tangible than a few entries
on the road map.

------
monyr75
What's really interesting in the comments on this thread is that almost
everyone who has tried Dart reports liking or loving the experience. If all
those people would push a little harder instead of caving to the status quo,
we might just get wide adoption and a great experience for everyone. You
know...progress.

------
matt2000
Anyone have any experience with typescript vs. dart? I'm thinking of learning
one of the two for frontend and wondered if anyone had any success or horror
stories either way. Thanks!

~~~
monyr75
I develop with both, and Dart wins hands-down. ES6/TS adds a lot of Dart's
best features to JavaScript, but without getting rid of JS's annoying
problems. Many here have mentioned that Dart's standard library is among the
best there is, and that's no exaggeration. That alone makes it better.

Whenever I have a choice, I always use Dart. The tools (analyzer, profiler,
etc.) automatically make me twice as productive as when I use JS.

~~~
matt2000
Thanks, very helpful. And did you find any problems debugging the javascript
output in the browser?

~~~
monyr75
Dart uses map files for debugging in the browser, but if you use an IDE like
JetBrains WebStorm or Eclipse, you can debug right in your editor environment
without the provably harmful context switch.

------
systems
well... packt free ebook for today happens to be a dart book Dart Cookbook
[https://www.packtpub.com/packt/offers/free-
learning](https://www.packtpub.com/packt/offers/free-learning)

9 hours left from the time of this posting

------
Brad811
I'm rooting for you guys :) I've really enjoyed working with Dart

------
ChekhovHemingwa
The comparison about commit velocity across popular languages is interesting
on its own (sec 2 in the article).

Here's the discussion it spawned for Scala, which surprisingly lags behind its
successor Dotty in that metric:
[https://www.reddit.com/r/scala/comments/405zw6/commit_veloci...](https://www.reddit.com/r/scala/comments/405zw6/commit_velocity_for_dotty_surpassing_scala_last/)

------
vinceyuan
I heard Dart before, but didn't know it's created by Google until now. I am a
fan of Go. I like goroutines and channels.

Why does google create two new languages?

~~~
StevePerkins
Google is a massive organization, and this is probably the LEAST ridiculous
example of redundancy! I've lost count of the number of database systems
they've developed.

I don't know if they're still as committed to this today, but historically
Google has been famous for allowing their engineers to spend some percentage
of their time on self-directed side projects. This leads to lots of engineers
working on the same sorts of things in different ways.

~~~
danellis
Some of Google's databases are just more functionality on top of an existing
one, though, rather than being created from scratch. Spanner is built on top
of BigTable, and F1 is built on top of Spanner, for example.

------
softinio
I gave Dart a try and liked it. In my opinion it has failed in being a
mainstream. It was bad enough that browser vendors where not embracing its VM,
but its downfall to go mainstream was in my opinion when Google themselves
announced that it would not be included in Chrome.

JS community are embracing ES6 and Typescript now. And for the none browser
market there are definitely a lot of better choices.

------
edderly
Do what you love.

Programming languages take years to incubate and in five years time you never
know what will happen.

Don't believe that a virtual machine based language is going to fly in true
embedded environments other than toys though. I've got more faith in
lightweight scripting languages for rapid development.

------
scriptproof
Using the same language on Android and iOS will be a huge advantage, once the
framework ready to production.

~~~
marvel_boy
Anyone can share his experiences using Dart for mobile?

~~~
on_and_off
You can have a look at the flutter demo app.

I only tested the Android version and it is still extremely early.

Very basic samples that don't run very well and implement Material elements in
an uncanny valley kind of way compared to the existing web & mobiles
implementations.

Not to mention that Android with Java/Kotlin has a truckload of tooling that
Dart would have to replace.

~~~
mwcampbell
And Flutter has no support for accessibility or localization yet.

I think it takes a lot of hubris to implement a new cross-platform widget set
that attempts to compete with the native widgets these days.

~~~
on_and_off
yeah, it is ambitious to say the least.

There are several parts of the android framework that I would like to see
rewritten from scratch (activity as a god object, love of inheritance
everywhere in the framework classes, weak UI/animation framework, etc) but it
is also a mature code base with tons of features, tools & open source
libraries built around it.

------
lassejansen
I tried Dart when looking for a typed language that compiles to Javascript. It
was nice but in the end I used haxe because it had a much smaller footprint.
Dart seems to include its own library while haxe sticks close to what
Javascript offers.

~~~
danellis
When was that? Dart started out generating _massive_ JavaScript files, but the
output has been significantly reduced in the past couple of years (something
to do with using transformers to replace some of the reflection at
transpilation time, I think).

~~~
lassejansen
About half a year ago. It turned 1500 lines of Dart into ~10000 lines of
Javascript. That might not be that much to handle for a webview but it was
quite hard to debug. I used it as a UserScript in WKWebView so I couldn't use
DartEditor. In comparison, the haxe code, which looked very similar to the
Dart code, was compiled into 1400 lines of pretty readable Javascript.

------
apo
Tried Dart a while back and really liked the language.

But I found the emphasis on Dart's use as an application building language
didn't fit my use case very well - compiling JavaScript libraries.

In short, I wanted to use Dart as a cleaner replacement for the Closure
libraries and compiler. It didn't work well. Not only was the JavaScript quite
large, but exposing APIs was a time-consuming manual process.

I noticed the change of focus to using Dart as a language that transpiles to
JavaScript for in-browser use. That sounds like what I'm looking for.

When will it be possible to use Dart to conveniently create minified
JavaScript libraries that expose well-defined interfaces?

~~~
munificent
I can't give you any time estimates, but what you're asking for is exactly
what the team has in mind with "DDC", the new Dart -> JS transpiler[1].

It produces much cleaner, more readable JS and is designed to make it much
easier to interop with JS code in both directions.

[1]: [https://github.com/dart-lang/dev_compiler](https://github.com/dart-
lang/dev_compiler)

------
andybak
Do Dart and Typescript hurt each other's adoption? i.e. they are close enough
that it 'splits the vote' and what might result in critical mass for one ends
up with both feeling like they are marginal contenders.

------
davinchi
And what's the future of Go language?

~~~
rashthedude
I'm far from being an expert in Go or know the specifics about future plans
but from what I've gathered it does seem like a beautiful system language. We
mainly use it for writing lightning fast API's. I do have a feeling that it
will have a breakout year in 2016.

~~~
coldtea
Go is neither a systems language nor "lighting fast" (that would make C, C++,
Swift and all "ridiculous speed").

And what kind of APIs would one write in Go? The kind that can only be
consumed by Go programs?

~~~
dimfeld
Presumably the post above was referring to HTTP-based services, which of
course don't face issues of cross-language ABI compatibility. In this case Go
is often much faster than Ruby, Python, JS, etc., while still allowing
relatively quick development compared to even faster, yet lower level,
languages such as C/C++.

------
Keyframe
That's actually nice. I had the impression, for some reason, Dart was kind of
abandoned from Google or they shifted focus from it.

~~~
droidist2
Maybe because Google is backing TypeScript and using it for Angular 2

[https://jaxenter.com/google-announces-new-approach-
angular-2...](https://jaxenter.com/google-announces-new-approach-
angular-2-0-115228.html)

~~~
munificent
I feel like I sound defensive every time I bring this up, but Angular supports
three languages that are all equally first-class: JavaScript, TypeScript, and
Dart[1].

Angular 2 is _written_ in TypeScript because that felt that was the best
source language to transpile _from_. But then they have transpile that to JS
and Dart for users of those languages.

[1]:
[https://angular.io/docs/dart/latest/index.html](https://angular.io/docs/dart/latest/index.html)

~~~
droidist2
Interesting, thanks for the info.

------
edtechdev
The main thing stopping me from using Dart is the same thing as Java and
Python and others. It isn't designed to compile in the browser. You have to
use the command line or an IDE. I have no problems with those myself, but the
apps I am interested in involve letting end users create their own
apps/animations/simulations, etc. If they went forward with a Dart VM in the
browser, that would be great, but it sounds like that was one of the first
things they abandoned.

There are so many other languages that do compile in the browser and can be
used without relying on command line tools that there's no reason to pay any
attention to dart at all, even though I like everything else about dart:
[https://github.com/jashkenas/coffeescript/wiki/List-of-
langu...](https://github.com/jashkenas/coffeescript/wiki/List-of-languages-
that-compile-to-JS)

~~~
jug
Yes, when Dart was still recently released I fully expected at least Chrome of
all browsers to directly support it, and with it being an open source project,
it to perhaps even trickle out to other browsers as well.

And I saw a Dart-powered web, and it was beautiful. Calling it a Javascript
killer is a misnomer, because it's a Javascript eviscerator.

Now Typescript is here in full force and I honestly think that, assuming the
language isn't going to be browser supported, that this is a better idea. :/
Simply because TS is a superscript over JS, so developers can migrate their
projects over time. Regardless how much of it is still in JS, that is per
definition also TS.

I think that is a huge boon, along with Typescript definition files to TS:ify
libraries without having to restort to what the Dart guys seem to have been
forced into doing with full reimplementations (DQuery, Bootjack, ... rather
than simply downloading the appropriate files from DefinitelyTyped.org).

It's too bad, because _conceptually_ I like Dart more! Everything is so
coherent regardless if it's on the client or the server, and modern HTML5
features are suddenly just libraries in the language itself! I really like it,
I don't even have to "want" to like it, I already do. Kind of annoying. :P

------
voider1
Why is Google making all these languages? I mean, they have Go, use a lot of
Python, and now they're developing Dart? What they're playing at?

~~~
danellis
They made two languages. That doesn't seem a lot for a technology company as
large as Google. Nobody looks at Visual Basic, C#, F#, etc and says, "Why does
one company need so many languages?"

------
josep2
Alright I'll give this a serious look.

------
rhizome
A downside of Medium is that we have no clue who "I" is:

[https://imgur.com/wIqpJyN](https://imgur.com/wIqpJyN)

------
such_a_casual
Is JavaScript the only "language" you've programmed in? Personally, I prefer a
language that doesn't require large frameworks and libraries that are here
today, gone tomorrow for basic language constructs like name spacing or
library references. Personally, I prefer not having "engines" silently fail on
something as fundamental as syntax errors, causing bugs that can't be
reproduced or tracked down. Want syntax checking? You guessed it! Another
Framework/Library/Tool to learn or build! Not horrendus? Good Enough?
JavaScript is the language of Satan's incompetent stepchild.

~~~
danneu
I don't know how you can hate Javascript or any other language so thoroughly
unless you just finally branched out to your second language that you're
currently in honeymoon love with.

Took me two years of writing Clojure full-time to realize that there is no
best. There are only trade-offs. These days I mostly use Javascript.

~~~
such_a_casual
The story goes that I have played with many languages, but only used small
amounts of js as needed before building an extension for chrome. I have never
found a language to be so unfriendly to n00bs. One is absolutely required to
learn third party frameworks and libraries just to do anything useful. There
is a never-ending list of basic things that are not supported by the language.
I have never had to use a third party tool just to check syntax in any other
language. I don't see any trade-offs to using javascript at all. It is a
language just like most C-based languages with everything chopped out of it.
What benefits does javascript have over any other language?

> These days I mostly use Javascript

You don't use javascript, you use a framework for javascript. In fact, because
browsers don't fully support EMCA 6, you are probably even using a tool to
convert your javascript code.

I absolutely abhor javascript, to the point where I stopped working on my
chrome extension (which is < 500 lines at this point) until I figure out how
to do it in another language. Which will probably be clojurescript or
typescript.

~~~
monyr75
I think you would find Dart to be a true joy, given your complaints about JS.
I switched to Dart, and now even looking at JS code with all those stacks of
indented curly-braces hurts my eyes...

