Earlier quoted context omitted.
I had that same opinion in 2003.
I am developing software since 1986, mostly web in the last 8 years, my experience in the chaotic ways of web development only reinforces my opinion.
Dart Is Not the Language You Think It Is
121–130 of 143 posts
Re: Dart Is Not the Language You Think It Is
#122I don't know Dart but I m intrigued by this "Dart is purely object oriented". Seems that people don't like some fundamental characteristics of javascript: the functional part and the prototyped based OO style. Is it still possible to use this in Dart or it is like the author said, purely OO?
Functional programming goes far beyond that. It encourages things such as immutability, referential transparency, powerful pattern matching, the heavy use of recursion, and robust type systems.
JavaScript either does not support such techniques and concepts, or it makes them difficult to use. Thus it is improper to consider JavaScript a "functional" programming language.
The same goes for JavaScript's so-called support for OO. Prototype-based OO is one of the least-useful approaches to begin with, for real-world software development, and JavaScript even manages to implement it quite badly compared to other languages offering prototype-based OO. JavaScript's complete lack of class-based OO (although, we may see this change with future revisions of the language) further suggests that it's wrong to call it an "object-oriented" language.
I'm not sure we can even make this comparison. JavaScript is, at best, an imperative language that has tried, rather poorly, to partially incorporate concepts from more advanced programming language paradigms. It's hard to imagine Dart, or any other language, supporting more advanced concepts any worse than JavaScript already has.
Re: Dart Is Not the Language You Think It Is
#123Earlier quoted context omitted.
Yes and no, An important caveat that Dart as JavaScript runs in it's own isolate and communicates with existing JavaScript libs through ports. This js-interop code is nearly 500k unminified. And you won't be able to minify all your JS (dartJs + other js) into one lib, because dart js doesn't play well with standard tools. One can certainly interop with js libs, but it's not pretty. Dart is not near 1.0 yet, so there…
On the opposite side , with a little bit of "header" writing ( or none but you lose type safety ) , Haxe support direct use of javascript libraries , that's what makes Haxe better than dart in my opinion, and you can reuse all the code that is not tied to the DOM is C++,Neko,Java and Flash apps (and android + iphone + ... with the NME framework ). But Dart optional type system is still interesting.
Re: Dart Is Not the Language You Think It Is
#124Earlier quoted context omitted.
>Who is the audience for Dart? AS3, C#, Java, and JavaScript developers. That's why they went with C-like syntax. It's familiar to most people. >But web developers, who are the primary producers of JavaScript, will happily stick with Node.js, CoffeeScript, or plain JavaScript. I'm writing JavaScript for a few years now. I'm really tired of it. It scales very poorly and there is zero tooling. For example, JSLint is mo…
When I started seriously working with JavaScript, I decided to try to conform to community standards by using JSLint. I was shocked by how terrible JSLint was. It offered corrections for very straightforward constructs such as: var count = 0; for (var i = 0; i I have no idea why JSLint would tell me that I should move the definition of "i" to the top of the function (am I supposed to pretend I'm writing ANSI C for ob…
var foo = "The id number is: " + ++this.id + ".";
a Minifier may make that like
var foo="The id number is: "+++this.id+".";
which is a syntax error. Now of course you should be using a minifier that wouldn't be so stupid but it happened in our staging environment because some former employee used a very basic, yet aggressive minifier in the build process from Staging to Live.
JSLint gives you an option to turn it off though, plusplus:false. Same with the variable hoisting warning others have explained.
Re: Dart Is Not the Language You Think It Is
#125Earlier quoted context omitted.
Walled garden?? It's the most open language I know, fully OSS'ed with an extended license to include any implicit patents (removing Patent FUD), developed out in the open and accepting 3rd party contributions and inviting feedback to influence language design. Lars Bak also mentioned at Google I/O that they're in the process of trying to get it standardized, not sure what's left to do to make it any more "open" and i…
Let's not pretend that Google's open source products in any way follow an open development process. Do you notice anything in common about the recent committers? http://code.google.com/p/dart/source/list http://code.google.com/p/closure-compiler/source/list http://code.google.com/p/closure-library/source/list Their development is very much insular. That's not to say it's a poor idea to depend on these products, but t…
Re: Dart Is Not the Language You Think It Is
#126Earlier quoted context omitted.
The primary audience, is web developers. Dart is an ambitious attempt at simplyfing web development, reducing complexity and improving productivity which: - Provides a familiar language with clean semantics and low ceremony - Provides the fastest dev iteration times (there's no compile step, just edit + run in Dart VM/Dartium) - Provides ~10x faster start-up times with snapshots (Dart VM) - Provides faster run-time p…
That's not much. ES6, TypeScript, DOMFutures, FunctionFuture, asm.js, WebComponents, jQuery, r.js, node.js bring most of these features to JS. Not as slick and with some legacy warts, but it's good enough to make Dart merely an incremental improvement rather than a revolution. It's very disappointing that the first serious attempt to replace JS after almost 20 years is merely just another Java-syntax-like JIT-compile…
Every other attempt adds more layers and complexity and additional build times to web development, only Dart brings a clean re-write.
Re: Dart Is Not the Language You Think It Is
#127Who is the audience for Dart? Clearly it is first and foremost Google, whose programmers spend their days writing Java and C++ in an IDE like Eclipse. But web developers, who are the primary producers of JavaScript, will happily stick with Node.js, CoffeeScript, or plain JavaScript. For that audience, they are given a language with optional static typing (most don't want it) and an Eclipse-based editor (most don't wa…
Do you think the Gmail or G+ team spends all their days writing backend code? Google has some of the largest and most sophisticated web apps ever developed, e.g. the newly minted Google Maps. All of this is courtesy of the Closure Compiler, which uses optional static typing.
Re: Dart Is Not the Language You Think It Is
#128Earlier quoted context omitted.
>Who is the audience for Dart? AS3, C#, Java, and JavaScript developers. That's why they went with C-like syntax. It's familiar to most people. >But web developers, who are the primary producers of JavaScript, will happily stick with Node.js, CoffeeScript, or plain JavaScript. I'm writing JavaScript for a few years now. I'm really tired of it. It scales very poorly and there is zero tooling. For example, JSLint is mo…
>Seen that "WAT" talk? None of that. You realize Dart literally has broken generics? That the team thought covariant mutable collections was a good thing?
Anyhow, JavaScript doesn't have any kind of generics or types. Do you really prefer that?
Re: Dart Is Not the Language You Think It Is
#129Earlier quoted context omitted.
Your issue is not knowing JavaScript. No point to blame a JavaScript linter.
The real issue is that, as a programming language, JavaScript is poorly designed and quite broken. Its implementors and community have been quite unwilling to fix these issues, even after a decade and a half. As a result of this, it is still riddled with oddities in even extremely simple constructs. Even when one understands the reasoning behind why a tool like JSLint suggests what it does, this doesn't change the fa…
You can't really fix things. It would break the web. You can only add stuff on top.
>JavaScript's scoping and variable hoisting are unnecessarily broken [...]
It will get a bit better with ES6's `let` keyword. Annoyingly, that keyword was introduced with Firefox 2.0 (October 24, 2006) but you still can't use it.
Even Node.js needs a switch.
Re: Dart Is Not the Language You Think It Is
#130Earlier quoted context omitted.
All require javascript compilation for development AFAIK
Like Dart, because it will never be adopted by other browsers.