

Dart Website Relaunch with 1.0 Release - allanberger
https://www.dartlang.org/

======
adamors
I really fail to see the point of Dart, especially since awesome client side
frameworks like Angular already exist.

Why doesn't Google throw more resources at them instead of creating something
from scratch that has a very high possibility of being abandoned in the next
2-3 years.

~~~
WoodenChair
Because writing/improving yet another JavaScript client side library fails to
address the fundamental flaws with JavaScript which are well laid out.
ECMAScript 6 will likely correct some of these flaws, but the necessity for
backward compatibility continues to be a stumbling block. Dart is a clean
break and fresh slate while retaining a familiar syntax and
interoperability/compatibility.

Is it a long shot that it will unseat Javascript? Sure. But, competition is
good for JavaScript. Google's number one interest is in improvement across the
entire client side web app infrastructure since its business is built upon it.
It can push Dart while improving JavaScript in parallel.

~~~
nailer
I definitely agree that JS itself could be improved, but while Dart improves
some things, it makes others a lot worse. Look at the Fibonacci program on
dartlang.org, and compare it to _any_ language that's popular with web
developers: Python, ruby, Coffeescript or even scala. Multiply that
unnecessary overhead for every function in your app.

~~~
mraleph
Fibonacci function in Dart can be as easy as:

fib(n) => n < 2 ? n : (fib(n - 1) + fib(n - 2));

Examples on the main page just exists to show cases as much language features
as possible. It does not say that you _have_ to wrap your Fibonacci into a
class.

~~~
nailer
Maybe it's a matter of bad docs giving the wrong impression then? Examples
should be terse, the ability to create unnecessary wrappers don't seem like
much of a feature to show off.

~~~
mraleph
Strictly speaking it's not a doc. It's a snippet on the main page that tries
to show case available language constructs. I do agree however that wrapping
Fibonacci in a class looks a bit strange.

Documentation that showcases features in the terse form is available at
[http://synonym.dartlang.org/](http://synonym.dartlang.org/)

If you have better ideas you can file a bug or even submit a pull request for
the site: [https://github.com/dart-lang/dartlang.org](https://github.com/dart-
lang/dartlang.org)

~~~
nailer
Web pages showing people how to do things are documentation. No inclination to
contribute, Google have known that verbosity is a common reason for disliking
Dart for 750+ days and haven't done much about it. I'm fine using JS and, when
I want strong typing, know that Typescript is there.

------
mythz
Awesome congratz to the Dart Team on shipping a quality product to the world!

Really hope they're able to keep investing in Dart, they've got an amazingly
talented team and IMO Dart's one of the few languages in recent times with the
engineering prowess and right focus on fast iterative development, speed,
simplicity, flexibility and consistency that's pushing comp-sci forward.

~~~
xxgreg
"pushing comp-sci forward"

nit - The Dart team have explicitly said that they are not doing any features
based on new computer science research. The Dart project is built on pragmatic
engineering decisions, rather than "pushing comp-sci forward".

This is a good thing in my opinion.

------
tbassetto
The biggest announcement for me is that the Dart VM will be embedded inside
Chrome:
[https://twitter.com/dart_lang/status/400915745413939200](https://twitter.com/dart_lang/status/400915745413939200)

~~~
DoubleMalt
This has sadly the potential of making Chrome second coming of IE6, with
enterprises locked in a system that is too successful to have the incentive to
evolve.

As long as the Dart specification is not governed gy a body encompassing all
major browser vendors, this is a very dangerous development (And yes, I know
that being governed by a standards body seriously hampers the evolution of a
standard, but everything is a tradeoff...)

~~~
mythz
Such uninformed comparisons are getting extremely tiresome and I consider to
be the enemy of progress. There is nothing more that the Dart Team can do to
make it anymore open - they're doing as much as is possible.

This is nothing like IE, which is actually proprietary and closed-source. In
contrast, there is absolutely nothing about Dart that's proprietary. Dart is
100% open source, including patents grants, it's completely developed in the
open and for the last 2 years has seen steadily progress with feedback from
the public mailing list. It's actually a goal for the project that everyone is
able to freely use Dart in any capacity. Lars Bak already said that after 1.0
is shipped they're going to work on getting the language standardized. There
is nothing legal or technical stopping other browser vendors using Dart, any
hesitations are 100% political.

Dart is finally the first real alternative where we may be able to progress
beyond JavaScript, that as a core objective also compiles to first-class
JavaScript, i.e. many features dismissed because it couldn't be efficiently
transpiled to JS. I care about progress, the current state of web development
is fragmented and broken, we need to be encouraging more initiatives like Dart
that challenges the status-quo and is able to progress past the fragmented
inconsistent mess we have to deal with now in trying to develop complex, rich,
high-performance web apps.

~~~
DoubleMalt
The problem is that even if Dart is completely open and patent free (and I
agree that there is a vast difference between Dart and ActiveX in this
regard), if the other browser vendors like Microsoft, Apple and Mozilla don't
pick it up, it will still be a walled garden, even if the wall is built by the
others.

Also Google has shown signs of embrace, extend extinguish when it comes to
essential parts of Android, which makes me a bit wary.

I would love nothing more that Dart superseding JS as the goto language (and
compile target) for browser development, as it is doubtless a step forward.
But there are pitalls hidden on the way there and the outcome is determined by
the path we will take.

Of course hesitations are political, because the outcome will be determined by
political actions of everybody involved, Google, MS, Apple and Mozilla.
Technical merits alone don't guarantee a happy outcome, sadly.

~~~
mythz
Agreed, although it's not a walled garden when others are artificially putting
up the wall, since they continue to enjoy the complete freedom if they ever
want to take it down.

Luckily unlike other walled gardens, the quality of Dart2JS, i.e. first-class
source-maps support and many benchmarks showing it even outperforms hand-
crafted JS, ensures that Dart apps will continue to benefit and run in other
modern browsers even without their support, where the only difference will be
the start-up and runtime performance of the running code, so we end up getting
it back down to technical merits.

~~~
threeseed
How are Mozilla and Apple putting up a wall ? Dart maybe open source but it
still a proprietary, non-standard solution where ALL the committers work for
Google.

[https://code.google.com/p/dart/people/list](https://code.google.com/p/dart/people/list)

~~~
mythz
Please re-read the parent, I've replied saying it's not a walled garden when
others are choosing not to adopt it.

> Dart maybe open source but it still a proprietary, non-standard solution

You use the word 'proprietary' but I don't think it means what you think it
means. It doesn't mean you have complete access to the entire source code
implementation and freedom to use all of it or any of it, in anyway you see
fit. It doesn't describe a project that's driven by feedback in a public
mailing list, that welcomes external feedback and contributions, and it's
rarely used to describe a project with a core goal for it to have no-legal-or-
technical-barrier, free access, encouraging its wide-spread adoption.

By your definition most Open source projects are proprietary and non-standard,
where most programming languages aren't even standardized, the difference with
Dart is that it actually has the commercial backing that can justify the
effort in actually getting it standardized, which it plans to do now that Dart
1.0 is shipped, just as Lars Bak announced at Google IO.

Again like many OSS projects, the Dart project has taken external
contributions, but the brilliant minds that Google have brought in to work on
Dart full-time are indeed being paid to do so. It's not uncommon, to accept
Q/A verified external contributions but to ensure only employees have free
reign and project-wide commit access. Even Dart's internal contributions still
have to go through a Q/A code-review process.

------
polskibus
Does dart vm use type information to optimize? I can't find a good
explanation. I'd really like to use static typing to gain both speed and early
error checking.

~~~
mraleph
If you mean type annotations then no, right now Dart VM does _not_ use type
annotations to optimize things.

Dart VM features an classical adaptive optimizations pipeline that first
gathers type information from the run and then optimizes hot methods using
collected type feedback to specialize the code.

For more implementation details about Dart VM optimizing compiler you can
check out my talk from Strange Loop 2013
[http://s3.mrale.ph/StrangeLoop2013.pdf](http://s3.mrale.ph/StrangeLoop2013.pdf)

~~~
k__
When will it switch from JIT to AOT? (SCNR)

------
Yuioup
Cool. Does this integrate with Visual Studio / ASP.NET MVC ? Otherwise this is
a non-starter for me.

~~~
gte525u
Typically, you would integrate it with ASP.NET the same way you do any other
Single-Page App not written in JS or Typescript.

It ships with a dart2js compiler that you can use in VS. However, to really
get the ease of development you're looking for you'd probably use VS to
build/debug the backend, and additionally, the dart editor (special eclipse
version) to debug the front-end. You'd have to enable your backend to support
CORS calls for this type of setup. However, Once you are ready to deploy, the
app builds to HTML/JS/CSS files that you can just embed normally in your
solution.

I think what you're getting at is - is it better than JS or typescript +
angular or backbone? It'd probably a matter of taste. The language is
different from the "syntactic sugar" on top of JS that typescript is. Dart
lets your bridge to standard JS libraries (i.e., Jquery etc), but, it also
provides most of the functionality in the standard library. It provide a
built-in unit test and logging framework and a nuget style repository of other
libraries. Additionally, Dart's Polymer library provides an MVVM framework.
You can define controls and combine into single-page webapps.

------
robmcm
I can see Dart being big in enterprise, although with no support for IE7 and
IE8 this could be an issue...

~~~
pjmlp
Not until there is a support across browsers and a must have framework that
can only be used from Dart.

I still don't see any enterprise requests for CoffeScript, TypeScript or any
other language that targets JavaScript.

When you work in teams, everyone across the company that needs to touch the
source code needs to know the respective technologies.

~~~
robmcm
There is cross support in the form of Dart2JS although that's IE9+

That is true, but then I'm not sure they offer as much as Dart does. (Plus I
bet some MS shops use TypeScript).

You would think, but how many people developing Objective C know C well, it's
more true in the beginning but as you go on the need to know about the target
runtime diminishes. Do you know much about the JavaScript VM in the browser
and how that compiles to C?

~~~
pjmlp
The point is what language the enterprise cogs need to learn and the supported
browsers.

> Do you know much about the JavaScript VM in the browser and how that
> compiles to C?

Of course, if you want to write JIT friendly code you need to know the magic
JavaScript incantation code patterns.

There is a reason why all browser vendors have developer sessions on their
conferences about those patterns.

~~~
robmcm
What about C to assembler?

~~~
pjmlp
Same thing. That is what -S in gcc is for.

Other compilers offer similar flags.

And before you ask, Assembly manuals explain how many cycles an opcode takes
and what are the expected side effects on the chipsets.

~~~
robmcm
The relevance of that is pretty insignificant unless you are building a
framework or compiler. That's the point of abstraction.

~~~
pjmlp
Or if you don't care about performance.

------
nailer
> Dart is new, yet familiar

Yes, but most people who write web apps don't like Java syntax. Publicising
Dart without changing that won't stop the low adoption Dart's had for the last
two years.

Edit: a reminder that that was the biggest piece of feedback from Dart
announcement 776 days ago:
[https://news.ycombinator.com/x?fnid=oEG20axbbQ4CeS0NXvabbv](https://news.ycombinator.com/x?fnid=oEG20axbbQ4CeS0NXvabbv)

~~~
WoodenChair
I can't think of any language other than Go that had relatively high adoption
pre-1.0 . Of course I'm sure someone will point out a few examples... but I
digress: Last I checked Java was the #1 or #2 top programming language in the
world. Perhaps Dart makes it easier for a Java developer to do front-end web
development while using a familiar paradigm.

~~~
cromwellian
Reports of Java's death has been greatly exaggerated ;-)My guess is, Java8
will solve a lot of the whining about boilerplate types. The closure syntax,
is in someways, more economical than JS.

~~~
taude
I'm willing to be we'll still be talking about Java's impeding death in 10
years here on HN. With all the different languages supported on the JVM, and
new ones to be invented....it's not going anywhere.

~~~
robmcm
Or the fact it seems to be very prevalent in places like India and China.

The fact there is a new fashionable language in the valley doesn't mean it's
going to be popular world wide.

