Sunday, November 20, 2011

Dart Experiments

As i play around with Dart, I have added my code to github over here

The idea is to have a cube rotating using different keystrokes ( Based of an old assembly project)

Right now its projecting a cube using canvas. A new build of the dart editor was released today so it should be interesting to see how the JS has evolved.

Wednesday, November 16, 2011

Playing With Dart

When Dart came I was a bit harsh, criticizing the syntax and its closeness to Java. I felt that without even giving it a chance and playing with it that was a bit unfair. So after downloading the new Dart Editor and some sample examples later here are my quick thoughts on it

Whats Good :-

1) For people coming in from the C#/.NET and Java world, this is a great way to get started writing JavaScript and feel at  home. The syntax and styling make it really easy for anyone with those backgrounds to jump in feet first and start working with it

2) The editor is very nice and easy to use. Doesn't get in the way and the auto complete works well. I am not a big fan of Eclipse but this is really nice and easy to use and being minimal takes a lot of the confusing bits of Eclipse out and gets you straight into the nitty gritty

3) Did I mention intellisense ? I love it coming from Visual Studio and feel its important for a developer to have that available. Having a screen split across the screens to see docs as to what options I have with the object is not something I want to do. The editor does a good job here

Whats not Good:

1) Debugging. Those capabilities arent in the IDE right now and having to debug the obscure JS it outputs is a pain. I found myself switching  between Chrome and Firebug to figure out what my syntax errors were. Very annoying. A simple thing such as Lists having a fixed size on init and not being able to extend later is something the compiler should have picked up at compile time

2) The syntax, it just feels "old". I play a lot with Python and CoffeScript and would have liked the syntax to be along those lines ( its not a lot to ask for since the guy who wrote Python works for Google ). Is python still used there ?

3) Dart-to-JS is going to be the popular option here, and I doubt we will see the script type implementing dart as an option in all the major browsers. No way do I see IE implementing this at all. But going from Dart-to-JS does mean you give up on the performance gains that Dart promises running on the Dart VM

So far I think Ill stand with my earlier stance ( esp the syntax, more python please). But this is a .01 Proof of Concept and from the Groups messages it seems like optimizations, tree shaking,  changes to architecture etc are all on the roadmap so my initial opinion are bound to change as the language matures.

Lets see where Google plans to take the language.