Slashdot Mirror


Dart 1.0 Released

stoolpigeon writes "Yesterday marked the release of Dart SDK 1.0, a cross-browser, open source toolkit for structured web applications. The Dart SDK 1.0 includes everything you need to write structured web applications: a simple yet powerful programming language, robust tools, and comprehensive core libraries. The language has been somewhat controversial, but Google continues to move it forward." Reader slack_justyb adds some more detail: "The new release brings a much tighter dart2js compiler reducing overall JavaScript output up to 40%; Dartium — a version of Google Chrome that has the DartVM in addition to the JavaScript VM as native to the browser; PUB, a package manager for Dart add-ons; and several favorite 3rd party plug-ins that now come out-of-box, in addition to a lot of work for Dart server-side tools that can work to automate server side tasks and help in the construction of web pages. However Dart has many critics not only from the IE and Apple camps, as one would guess, but from the Firefox and Opera camps as well. In addition to the low adoption of Dart from third parties there are some asking where does Dart go from here? Especially considering that Google is one of the strongest pushers for EcmaScript 6."

69 of 121 comments (clear)

  1. It's a good idea to try it. by Anonymous Coward · · Score: 3, Informative

    If you've used JS in the past you'll see immediately why DART is so welcome. It's actually SANE!

    My productivity is probably 200% greater in DART then JS. But don't take my word for it, I'm jsut an ana coward!

    1. Re:It's a good idea to try it. by Joce640k · · Score: 1

      I guess all the people that use JavaScript for fun on GitHub are morons?

      There's an old saw about "millions of flies..." that might be applied here.

      The number of diners doesn't always reflect the quality of the cuisine.

      --
      No sig today...
    2. Re:It's a good idea to try it. by aztracker1 · · Score: 3, Informative

      I'm not sure what you are referring to... for the most part extensions to JS the language have been fairly limited in scope... Some of the ES6 stuff being an exception, that has been a work in progress for some time. Most of the ES5 extensions can be shimmed in, and are often abstracted via utility libraries like lodash. The *language* of JavaScript is *NOT* the Document Object Model (DOM) of the browser... People tend to conflate the two, but it's just not the same thing.

      --
      Michael J. Ryan - tracker1.info
    3. Re:It's a good idea to try it. by TechyImmigrant · · Score: 1

      >The *language* of JavaScript is *NOT* the Document Object Model (DOM) of the browser... People tend to conflate the two, but it's just not the same thing.

      But you never get to deal with one without the other. They are joined at the hip and the hip is badly dislocated.

      --
      I should use this sig to advertise my book ISBN-13 : 978-1501515132.
    4. Re:It's a good idea to try it. by TechyImmigrant · · Score: 1

      >The only reason they come up together is because there are not any practical alternatives for a lot of web development cases

      Which was my point.

      --
      I should use this sig to advertise my book ISBN-13 : 978-1501515132.
    5. Re:It's a good idea to try it. by TechyImmigrant · · Score: 1

      You are claiming I claimed something I didn't claim. At no point did I claim they were the same thing. I said they were connected, which they are.
      My point was completely on topic. The topic was the assertion that JS and DOM are independent. My assertion that for all practical purposes they are not.

      That you could replace JS with a different language is irrelevant. The combination of +DOM would still stink because DOM stinks.

      --
      I should use this sig to advertise my book ISBN-13 : 978-1501515132.
    6. Re:It's a good idea to try it. by aztracker1 · · Score: 1

      Well, there are JS bindings (V8 and SpiderMonkey) for a number of platforms/environments... from NodeJS, Synchronet, GLUEscript, and others... the language is actually fairly broadly available outside of the DOM.

      --
      Michael J. Ryan - tracker1.info
    7. Re:It's a good idea to try it. by aztracker1 · · Score: 1

      But.. you can use JS outside of the browser.

      --
      Michael J. Ryan - tracker1.info
    8. Re:It's a good idea to try it. by TechyImmigrant · · Score: 1

      But I could use a better language outside of the browser. JS isn't a terrible language, but it's no Python.

      --
      I should use this sig to advertise my book ISBN-13 : 978-1501515132.
  2. Dart2JS is faster than JS?! whatever by Anonymous Coward · · Score: 1

    It seems rather imbicilic to say that Dart2JS is faster than JS.

    1. Re:Dart2JS is faster than JS?! whatever by Anonymous Coward · · Score: 1

      Please, don't do that in front of the kids, that's gross.

    2. Re:Dart2JS is faster than JS?! whatever by Blaskowicz · · Score: 2

      It's rather imbecillic to handwave it without providing any reasoning behind it. Look what Mozilla is doing with asm.js and "compile to javascript" compilers.. You can compile a high level language to a low level, restricted subset of javascript which then runs very fast in the browsers's JIT engines. Doesn't sound too great maybe but the resulting execution speed can possibly be better than by using javascript's high level features and libraries instead.

    3. Re:Dart2JS is faster than JS?! whatever by slack_justyb · · Score: 4, Informative

      That is correct. When writing my piece for the story I wanted to ensure that I conveyed the correct idea that the Dart2JS compiler now generates up to 40% less JavaScript than previous versions of Dart2JS, not that the JavaScript itself that it generates is 40% faster.

      As far as speed goes, there is all kinds of data on that facet on the Dart website. That will no less generate large amounts of debate about the figures presented by Google about Dart's performance. Just for the comedy of it, dart2js may generate less JavaScript, but will generate at least 60% more debate about its use.

      If I was not clear on the whole point by this part of the story:

      The new release brings a much tighter dart2js compiler reducing overall JavaScript output up to 40%

      Then it was an honest mistake. I work with computers not the English language. :-)

    4. Re:Dart2JS is faster than JS?! whatever by Vanderhoth · · Score: 1

      I think he was being facetious and the point was to show how poorly Bing actually works. That was my take on reading the returned results anyway.

    5. Re:Dart2JS is faster than JS?! whatever by Anonymous Coward · · Score: 1

      Read the article. Look at the graphs. That is exactly what they claim.

    6. Re:Dart2JS is faster than JS?! whatever by Joce640k · · Score: 1

      Dart2JS generetes 40% less JS code than it previously did.

      Is that good or bad?

      If it used to generate code that was megabloated then trimming it down to merely 'humongous' isn't much use.

      --
      No sig today...
    7. Re:Dart2JS is faster than JS?! whatever by AC-x · · Score: 2

      Next you'll be telling us that an optimising C compiler can't create faster code than readable hand-written ASM...

  3. And I'd learn to use it by i+kan+reed · · Score: 3, Insightful

    If I hadn't come to absolutely loathe and distrust everything Google does over the course of the last few years.

    1. Re:And I'd learn to use it by LWATCDR · · Score: 1

      Good for you. Oh Slashdot uses google services so you might as well just not post here.

      --
      See my blog http://ilovecookes.blogspot.com/ for light hearted technical information.
    2. Re:And I'd learn to use it by Anonymous Coward · · Score: 5, Insightful

      This is totally Microsoft's VBscript for the web, and NaCL is their ActiveX. They're taking their role as the new Microsoft too seriously...

    3. Re:And I'd learn to use it by Manfre · · Score: 1, Insightful

      Chrome is the new IE6. A site I maintain has dropped IE6, but has recently been required to make CSS tweaks to fix box and other layout issues with Chrome.

    4. Re:And I'd learn to use it by i+kan+reed · · Score: 1

      No, you can't avoid every webpage google has stuck its fingers in these days. All you can do is adblock every doubleclick, adwords, google+, and google analytics XSR on the Internet, and avoid using their services directly.

    5. Re:And I'd learn to use it by spacepimp · · Score: 2

      So Chrome is going to languish for 6 years without a hint of improvement and be the core source of all malware and drive by infections on the web?

    6. Re:And I'd learn to use it by knarf · · Score: 2

      You distrust a programming language? Why? The source is available so instead of loathing and distrusting you could download and check. If it turns out there are no small Googoloompas hiding in there you could use it, just like you might use products related to other companies who have behaved in less desirable manners.

      --
      --frank[at]unternet.org
    7. Re:And I'd learn to use it by SoupGuru · · Score: 1

      I still trust them a hell of a lot more than I do the other big players in technology.

      --
      What doesn't kill you only delays the inevitable
    8. Re:And I'd learn to use it by Princeofcups · · Score: 1

      If this were Microsoft, then they would wait until they had a critical mass of users, and then start forgetting to fix bugs for anything other than Chrome. But this isn't Microsoft, so that would NEVER happen. Right?

      --
      The only thing worse than a Democrat is a Republican.
    9. Re:And I'd learn to use it by ShieldW0lf · · Score: 1

      He who rides a tiger is afraid to dismount

      --
      -1 Uncomfortable Truth
    10. Re:And I'd learn to use it by dwater · · Score: 1

      Ah, sure, the source is available, but what about the source of the compiler what was used to compile it? If you can't get the source of the original compiler, the only recourse is to actually check the output of the compiler - I suppose you could also *de*compile the compiler and check *that* source too.

      --
      Max.
  4. Yay.... by Anonymous Coward · · Score: 1

    Yay, another web programming language to learn.

    Sigh...

    1. Re:Yay.... by bluefoxlucid · · Score: 1

      I was thinking about writing a JavaScript to CIL to use Mono to back JS: the engine would produce CIL that loads into a CIL runtime, along with a support library that connects to the DOM. Then: WEBCIL-Python.

    2. Re:Yay.... by SpzToid · · Score: 1

      Yes. Back in the day we had FORTRAN and we liked it. Especially punching the cards and waiting for everything to come back.

      Now would you mind stepping over and on to the sidewalk so I can water that patch of grass you're standing on?

      --
      You can't be ahead of the curve, if you're stuck in a loop.
    3. Re:Yay.... by SpzToid · · Score: 1

      Sorry, replying to my own post, because I meant to reply to the AC GP in my previous post. I hit the wrong message in the thread to reply to.

      --
      You can't be ahead of the curve, if you're stuck in a loop.
  5. Reducing up to? by wonkey_monkey · · Score: 1

    reducing overall JavaScript output up to 40%

    Err... what?

    --
    systemd is Roko's Basilisk.
    1. Re:Reducing up to? by robmv · · Score: 1

      Initial versions generanted big JavaScript files using dart2js, there have been a lot of work optimizing that

    2. Re:Reducing up to? by AC-x · · Score: 1

      It reduces the size of the Dart to JS compiled output by 40% compared to previous versions.

  6. Re:Cross browser? by Alarash · · Score: 2

    I'm a network engineer, and I do some web development as a hobby to understand better the application layers and all that payload I transport on the wires.. I hate Javascript because I find it hard to debug in a browser. I like having a proper IDE to help me debug my code. If then they convert that code to JS and it works the same, it works for me. I'm not a professional developer so maybe the ones who are should write in JS directly, but my experience is that JS is not a great language because of the debugging. I prefer C# and Java because of Visual Studio and Eclipse's help in debugging.

  7. Re:Cross browser? by robmv · · Score: 2

    Javascript isn't rocket science to use. You've just got to put in the effort to read a couple books to understand that it requires different design strategies from other OO languages. The scoping, prototypes, and events are actually really nice if you bother to learn how to use them properly.

    I don't hate JavaScript, but I wish it started to have a real and modern API. DOM objects and a few basic types is not constructive, everyone is adding external libraries to do simple things, using different libraries so you don't have a base API to learn. I am not talking DOM manipulation level APIs like jQuery, but about a good collections, async, crypto, etc APIs. JavaScript core available APIs is a mix of bad basic types (like only the Number type for every numeric value) and HTML spec APIs every one of them with their own conventions

  8. What about a dart plugin? by jnowlan · · Score: 2

    How much effort would it take to create a plug-in for FF and/or i.e. that contained the dart vm?
    Would it get you anything? What would the issues be?

    1. Re:What about a dart plugin? by slack_justyb · · Score: 1

      Don't know about the coding side of it, but I would guess it to be pretty straight-forward process since the VM is open sourced. I think the better question would be how much political effort would it take to get a plug-in for FF and/or IE into the hands of people? Pure JavaScript folk are pretty damn hard-core about their language and Dart to them just seems like a solution to a non-existent problem. Besides, with Dart being a plug-in, you'd have websites once again going into the "check for plug-ins" hell that they are trying their best to get out of.

  9. Re:Cross browser? by slack_justyb · · Score: 3, Insightful

    I think your arguments are pretty valid and I am by no stretch of the imagination a pro-Dart guy, but I believe that the "cross browser" claim comes from the olden days of cross platform languages. C/C++ had (has, just in case the past tense is a really bad choice) cross platform compilers they take C/C++ code and compile it to a language that the target platform understands. For example, C to ARM/x86/amd64/MIPS... compilers.

    So my guess here, and it is just a guess, is that Google is using the same rationale to justify calling this a "cross browser" language, because the compiler can turn Dart into a language that can be understood by other browsers, much like a C compiler can compile into different paltforms. Arguments about if that is an accurate equation are totally justified and most likely will ensue hereafter. I'm just tossing up a guess as to why Google felt like that was an accurate statement.

  10. No, no don't mod the parent down! by slack_justyb · · Score: 2, Interesting

    I think the parent has a good argument, maybe just no stated in the best of terms.

    However, on the Dart site it says that Dartium, the DartVM enabled version of Chrome, will be one of the major focuses of the Dart team. Somehow, I have a sinking feeling that maybe, just maybe, Dart and NaCL are going to become *major* line items for ChromeOS and Chromebooks. Much like how ActiveX and VBScript became pretty important pillars in Microsoft's platform.

    So while on the face of it, it sounds like a shrill. It actually can be rather thought provoking about the future of Chrome and Google. Just for a second think about where VBScript and ActiveX went during their lifetime and what they eventually evolved to. Granted we all now look back and see VBScript as the useless thing that it is, but in it's day, it provided a very powerful way of making offline enabled web pages and was featured heavily in WSH for admins until replaced by PowerShell. Clearly, Google hinting at Dart in the server is an indicator that Dart very may well have a life not unlike VBScript.

  11. Re:Cross browser? by Nixoloco · · Score: 1

    If you haven't tried it, you should try Firebug. It helps debugging Javascript in the browser quite a bit.

  12. Re:Cross browser? by slim · · Score: 3, Informative

    Any language that cross-compiles to JS is cross-browser. Correct.

  13. Re:Cross browser? by royallthefourth · · Score: 1

    Maybe you don't "get" Google's Dart strategy. It's ActiveX all over again, but with more technical finesse.

  14. Why not python? by Daniel+Hoffmann · · Score: 1, Insightful

    Why don't they just put the python runtime sandboxed? Why create a new language? Why not Lua or Ruby? Why not all of them so I can choose? All these languages have run-times on most major platforms (except iOS because, you know, Apple). Can't each browser just come up with a way to sandbox the language and provide the hooks to the DOM?

    But really, the main problem isn't even javascript. The REAL problem is the DOM, it sucks manipulating it at run-time. The DOM was made to build documents, not applications. We need some real desktop-like api for building applications that allows little boxes on the screen to open html documents.

    1. Re:Why not python? by Lisandro · · Score: 1

      Much, much agreed. I would *love* to see Lua on a browser. It is Python after a marahton diet.

  15. Re:Cross browser? by Daniel+Hoffmann · · Score: 1

    Chrome has the best debugger I have seen. I find easier to debug Javascript code than Java code on Eclipse. It is one of the reasons I don`t like TypeScript and its similars, they compile down to Javascript which makes harder to debug the original code because the debugger only sees the Javascript code.

  16. Burned by GWT by smist08 · · Score: 5, Insightful

    After being burned by Google abandoning GWT, I would worry about adopting Dart. Won't Google just lose interest and abandon it after a year or two. Won't we just see a new project start up almost immediately for some newer better web language? Not sure I'd jump in on this one.

    1. Re:Burned by GWT by Anonymous Coward · · Score: 2, Insightful

      *Citation needed

      At a quick glance, it looks to me like there was a GWT release just today...

    2. Re:Burned by GWT by angel'o'sphere · · Score: 2

      Since when is GWT abandoned?

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    3. Re:Burned by GWT by CyDharttha · · Score: 1

      GWT has been open sourced. I am hopeful that this can only be a good thing. There is still at least as much activity on the project as when it was not open source. The 2.6.0 RC1 release notes look great. Just recently a Google employee was working on a bug I was tracking. And there's the GWT Create conference coming up.

      I was worried about GWT when I saw Dart coming up and getting attention, because I've enjoyed writing apps in GWT, and would like it to continue to be an option when we're scoping new projects. So far what I'm seeing from the new status of the project is helping to keep my confidence.

    4. Re:Burned by GWT by slack_justyb · · Score: 4, Insightful

      What? Do you mean 2.6.0 RC1? 2.6 looks to be more of a clean up of the 2.5.1 stuff rather than anything new. If anything the main thing that 2.6 brings is that they brought Java 7 into the picture. I wouldn't say that Google *has* abandon GWT, but they sure are making the common gestures of getting ready for a good old fashion keelhauling.

      Now for just my opinion, GWT sucks. It's a messy looking API and lacks a ton of flexibility. For example, trying to implement custom UI for your web page is painful and totally unpleasant. More so than say making the same customer UI in Java Swing (which is pretty painful in of itself). In my opinion, and you my mod me down for it, is that anything that is worst to do in (insert framework here) than it is in Java should not exist.

    5. Re:Burned by GWT by slack_justyb · · Score: 1

      Well I work with Java all the time and I find Swing great to use, but when I want to build my own user interface elements, then yes, I find it very painful indeed. I've done custom widgets in Cario/GTK, .NET, and even for Android; and Swing is pretty up there for the bar that needs to be crossed to have a custom widget. I don't find Swing all that difficult to use at face value but just mucking about AWT or even SWT is far better than trying to muck around and build custom GUIs in Swing.

      In that respect, GWT is worst. GWT makes a lot of assumptions about how you want to convert Java into JavaScript. When you want to create your own web elements, not only do you have to build it using some of the worst API I've seen, you actually have to fight the assumptions that GWT tries to make right out of the box. You are literally fighting on two fronts to just make a damn clock widget or rich editor widget. It is ridiculous.

      GWT on a whole is a pretty sad state. It integrates poorly with JEE frameworks and when it does, it's literally shoe-horned. You'll find that something like JSR 356 is a waaaaaay better approach to bridging the gap between server side code and client code, and I'd hope that the Java community can keep hitting excellent projects like this. Because Google isn't doing it with their idea of interoperability.

      Also since you want to be mincing words between library and framework. If you happen to head over to JSR 296 you'll see that the JSR refers to it as "The Swing Application Framework". Maybe you should head over there and educated them that they should have called it "The Swing Application Library". That being said, I believe your retort to have loss any of its credibility but seriously, this is Slashdot, does anyone think anything on this site is credible? Hope you are still laughing though.

    6. Re:Burned by GWT by slack_justyb · · Score: 1

      Nope wait, wait!! That last reply, the JSR thing not correct. I'll totally admit wrong when wrong and JSR 296 isn't Swing itself but the aborted effort to build the application framework a while back. My bad, got that wrong. All shit tossing about that you want totally justified. That is all.

    7. Re:Burned by GWT by angel'o'sphere · · Score: 1

      I guess if someone likes GWT or not is a matter of taste. I'm quite content with it, however I wished it would use less tables and more divs.
      I like the API of it, but I never made really "custom" widgets. However there is a quite good tutorial how to do that. I did not asume it is difficult, same for Swing, there are lots of tutorials how to make your own widgets.

      OTOH most of the time it is more efficient to write your own look and feel instead.

      Well that JSR for an Swing based Application Framework, was a one man project. He relied a lot on annotations (which I don't really like, but again that might be a matter of taste).

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  17. Re:Cross browser? by angel'o'sphere · · Score: 3, Insightful

    It has nothing to do with ActiveX at all.
    ActiveX is a fancy *dll, which has full access to the System.
    Dart is a sandboxed, either by the JavaScript Engine or the Dart Engine.

    --
    Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  18. Re:Cross browser? by dtfinch · · Score: 1

    I never found Typescript's output to be that hard to read, since it preserves comments and changes the code very little apart from rewriting class definitions.

    You can enable source maps, which the Firefox/Chrome debuggers can use to show you the original code when debugging compiled code. And some minifiers like UglifyJS can transform source maps to continue working after minifying.

  19. Re:Cross browser? by Dracolytch · · Score: 1

    If you're lucky.

    --
    This sig has been enciphered with a one-time pad. It could say almost anything.
  20. Re:Cross browser? by narcc · · Score: 1

    You've missed the parents point. This is not a technical issue.

  21. Re:Cross browser? by Kielistic · · Score: 1

    Look here. The Dart devs have been very open about their goals and their choices. They do plan standardisation and only want to develop the language to where they want it (where they think it will be good enough to drive adoption) before handing it off.

  22. Re:Cross browser? by Kielistic · · Score: 1

    What does renaming a method have to do with their choices on when to hand off to a standards body? The whole point of not being in the hands of a standards body (and until now being below version 1.0) was their ability to make unanimous decisions like this. They want the language to be designed with a singular vision which they believe leads to a stronger language. They even give evidence for this belief.

  23. Re:Strongest pushers for EcmaScript 6? Oh Really?? by slack_justyb · · Score: 1

    Wait a second, are you really holding JS extensions in the Firefox experimental against Chrome stable? Really? Are we doing that now?

  24. Can the same be said of Microsoft? Or Apple? Or .. by walterbyrd · · Score: 1

    Do you think Google is the only big tech company that drops products, or services?

  25. How many browser based web programming languages? by walterbyrd · · Score: 1

    Tons of server based web programming languages. But, as far as I know there is only one, widely used, language for programs that run on the client browser.

  26. Re:Windoze only? by bug_hunter · · Score: 1

    I can't speak to if DartEditor uses Java (and if it does, maybe it just bundles a stand alone bundled JRE?) but it works on most flavours of Windows, Mac and Linux
    https://www.dartlang.org/tools/editor/

    I'm sure Google have done the occasional Windows only thing, but in general it's really not their style.

    --
    It's turtles all the way down.
  27. Re:Windoze only? by sproketboy · · Score: 1

    Yeah it's based on Eclipse. I did find the Mac/Linux downloads so OK I'll try it.

  28. Dart needs JavaScript by Hypotensive · · Score: 2

    What I find hilarious is that the Dart language website (dartlang.org) actually requires JavaScript to work.

    1. Re:Dart needs JavaScript by dwater · · Score: 1

      ...even if you use their dart-capable browser?

      --
      Max.
    2. Re:Dart needs JavaScript by Hypotensive · · Score: 1

      Well, after reading further I find that Dart compiles down to JavaScript in any case, presumably even in the Dart-capable browser, which makes it about as useful as a fifth wheel.

      Also of note is this:

      if (1) {
      // this will be executed in JavaScript and other sane languages
      } else {
      // this will be executed in Dart
      }

      Got to love it when those language designers have such hubris that they think they can do the exact opposite of what everyone else in the world is used to.