10 ms·
Dart Website Relaunch with 1.0 Release
- nailer 13y ago> 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 13y agoI 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 13y agoReports 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.
- ajanuary 13y agoOn the consumption side, yes. As far as I can tell, you still need to write out the function interfaces :(
- cromwellian 13y agoBut that's exactly the way library APIs should work, with all the pain and labor going into the API declaration, and the users of the library experiencing very little. In type inferenced statically typed languages like ML, Scala, or Haskell, you can get away with not mentioning the types in the bodies of most functions. The type declarations at the library level serve as useful documentation.
- ajanuary 13y agoThat creates a somewhat artificial boundary between libraries and consumers. I write plenty of code at all layers that would benefit from being able to accept code as an argument. If I want a private helper method that takes some code as an argument, do I have to create and name a function interface just for that? Yes, Javascript's anonymous function syntax is needlessly verbose, but that's trivially fixed and will be in future versions. Changing Java to not need a function interface is a much bigger challenge that I'm willing to bet won't come about for a long time, and is going to be a source of frustration for lots of people as they realise how useful cheap anonymous functions can be.
- cromwellian 13y agoI'd argue that there already is, in well written libraries, an artificial boundary. Library APIs often have to be written for the consumption of others, so more care is usually given (in well written) libraries. You don't really need to create any function interfaces for most expressions since the most common ones are pre-defined (Supplier, Consumer, Predicate, Function, UnaryOp, BinaryOp, etc), and the basic rules allow a lot of flexibility. I've been doing a lot of Java8 recently due to work integrating it into GWT (https://plus.google.com/+RayCromwell/posts/C4QYmWWQguT https://plus.google.com/+RayCromwell/posts/C4QYmWWQguT) and the experience has been delightful. In actual use (as opposed to testcases), it's been very economical, especially the this::foo constructor vs the JS equivalent which needs bind(), and the fact that you get good auto-complete is great.
- ajanuary 13y agoMy comment was poorly phrased regarding libraries. What I meant was there's plenty of code if want to use lambdas for that isn't a carefully planned api boundary. Even with the provided function interfaces I worry there will be cases they don't cover which means people won't use anonymous functions where they're useful. However, given you seem to have used Java 8 and. I haven't, I'll relent :)
- taude 13y agoI'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 13y agoOr 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.
- nailer 13y agoVersion numbers are arbitrary, and most of the JS community were quite ready to check out dart as soon as it was released. Agreed re existing java developers though. But even in the java community, scala syntax is popular for the same radios dart is unpopular for web devs. I've seen more typescript interest than I have dart interest, again because type safety has nothing to do with unnecessary verbosity. Languages have users just like programs do. We know, as developers, that making users do extra work is poor. Java is renowned as the 'I studied computer science at university but...' language. Why is Google unnecessarily repeating the mistakes? Google: make dart 2 cleaner and you'll immediately engage not just java users, but existing web developers and people new to software as well.
- munificent 13y ago> most of the JS community were quite ready to check out dart as soon as it was released. There are definitely early adopter, bleeding edge types who love to look at things that are brand new. But we've gotten a lot of feedback from developers saying they are interested in Dart but not comfortable using it in mission-critical apps when the language is still changing. Going 1.0 is a big deal for those people. > I've seen more typescript interest than I have dart interest, again because type safety has nothing to do with unnecessary verbosity. I'm not sure what you mean here. My experience has been that Dart is a good bit more terse than TypeScript (getting rid of "this." everywhere certainly helps). Are you trying to say Dart is unnecessarily verbose, or that that doesn't matter?
- nailer 13y ago> Are you trying to say Dart is unnecessarily verbose Yes. See other posts.
- munificent 13y agoThe only post I saw from you on that was main(). I'll reply there.
- threeseed 13y agoPlease. Every professional developer (including Java focused one) knows enough Javascript to do what they need. Especially with frameworks like JQuery, AngularJS, KnockoutJS etc it all really isn't that hard. And on large projects which are the domain of Java/.Net developers you often have dedicated Front End developers anyway.
- robmcm 13y agoPeople that write Java don't like JavaScipt, would be another way to look at it. Working on large scale (tens of developers) web apps has serious issues with JS, and Dart can address some of that. I don't expect to see AirB&B running via Dart, but Gmail, Google Docs etc will really benefit, and hopefully pave the way for some serious desktop caliber applications.
- moondowner 13y ago> People that write Java don't like JavaScipt, would be another way to look at it. Not true, at least not in my case :) There are webapps that use Java (or any JVM language) on the back-end and JavaScript on the front-end. Check out Addy Osmani's "Making Maven Grunt": http://addyosmani.com/blog/making-maven-grunt/ http://addyosmani.com/blog/making-maven-grunt/
- nailer 13y ago> People that write Java don't like JavaScipt, would be another way to look at it. Sure, but for different reasons: principally, lack of type safety. That's completely orthogonal to syntax.
- robmcm 13y agoWhich Dart has. (Type safety)
- nailer 13y agoYep. I think everyone in the discussion likes (either optional or mandatory) type safety. That's why we want the syntax to be better. Type safety doesn't require semicolons, wrapper classes, wrapper functions, explicitly defining whether everything is public or private because there's no default, or lots of brackets.
- robmcm 13y agoWhich Dart has. (lack of wrapper classes, wrapper functions, lots of brackets)
- adamors 13y agoI 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 13y agoBecause 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 13y agoI 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.
- WoodenChair 13y agoYou mean the graphical one where they use storage, forms, and events? Let's not be misleading... Hello World in Dart is: main() { print("Hello World!"); }
- nailer 13y ago> main() { print("Hello World!"); } Yes, that's my point. Why not just print("Hello World!"), like everything else?
- polskibus 13y agoDoes 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 13y agoIf 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__ 13y agoWhen will it switch from JIT to AOT? (SCNR)
- tbassetto 13y agoThe 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
- robmcm 13y agoI thought this was always the plan, which would make Chrome a must of people using Dart apps. Question is if other browsers would include the DartVM (I guess Opera will) or if they will rely on the JS version.
- pjmlp 13y agoYes, this was spoken at Google IO, in a talk where it was mentioned plans about merging v8 and dartvm. Sometimes it pays off to watch the sessions. :)
- robmcm 13y agoBut only Opera and Chrome use v8 as of now.
- pjmlp 13y agoYeah, but I was speaking about developer sessions in general, regardless of the technology. A good developer should try to get as much information as possible about his/her tooling. I remember the days where all I could learn about computers was trial and error, helped by what the local library could offer, if anything.
- threeseed 13y agoI can't imagine Mozilla or Apple adopting Dart unless it is ratified as some standard where they have the ability to contribute to its future roadmap. Apple in particular was burned by Flash and I can't imagine being willing to go down that path again.
- DoubleMalt 13y ago
- Yuioup 13y agoCool. Does this integrate with Visual Studio / ASP.NET MVC ? Otherwise this is a non-starter for me.
- gte525u 13y agoTypically, 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 13y agoI can see Dart being big in enterprise, although with no support for IE7 and IE8 this could be an issue...
- pjmlp 13y agoNot 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 13y agoThere 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 13y agoThe 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.
- mythz 13y agoAwesome 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 13y ago"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.