Do I need a Dart?

Original author: Matthew Butler
  • Transfer
I love Dart, it is a very powerful language for writing both client and server parts. You can create html pages and html games on it, using only the DOM or using WebGL / Canvas. You can write console text games, once, I created a multiplayer console game on Dart that worked through telnet. I used this language to create scripts, poll and manage remote equipment and store the results in a database, on the basis of which beautiful graphics could be obtained later.

But Dart is not a panacea and answering the question in the article title: it all depends on what needs to be done. For example, you cannot write an operating system on it. You cannot get the same performance that C gives when writing games (those not for the browser). It is not optimized for processing large scientific data. Dart is just a tool with its purpose. You will not catch a shark with a butterfly net.

Javascript can do the exact same thing as Dart. And JS has an advantage in the number of ready-made libraries. I would advise you to avoid them when learning JS, the use of libraries by beginners can lead to a potential programmer knowing how to write in jQuery, but not like JS, and ultimately to poor performance of the developed sites. I have already corrected such work.

When using only standard libraries, Dart has an advantage over JS right out of the box. Many APIs already take into account differences in browsers, while JS requires an individual approach (fortunately, now this is not the big problem that it was when Dart was just released). The functionality of standard libraries in Dart provides such capabilities that are not in pure JS and for which you need to use third-party libraries. Which can conflict with each other or change the behavior of JS in such a way that other libraries will behave in an unpredictable way.

Dart with conflicts is simpler. Firstly, there are fewer libraries themselves, and secondly, there are standard conflict avoidance mechanisms. Fewer libraries have their own advantages, for example, you need to consider fewer different options to choose the one that suits your project.

And the deciding factor that will influence the decision whether Dart is worth your time is the developer community. JS has been gathering people around for a long time, the Internet is filled with lessons, forums, examples and most importantly the people who use it. Dart, on the other hand, is basically a community of people for whom this language was not the first, and it is relatively small. Some can not cope with the first difficulties in learning and throw language.

Because the Dart community is smaller, and because its followers are more experienced, there are fewer lessons, and in particular fewer lessons, that target newcomers to programming. There are books and articles, but their number is negligible compared to JS. This minus is balanced by the fact that the Dart community is extremely loyal to its language and promotes it in every possible way. Of all the communities that I have met, the Dart community is the most open and welcoming.

In the end, I would like to note that the experienced developers with whom I spoke chose Dart in favor of JS for the reason that the language itself and its standard libraries solve the key problems that prevented them from using other languages. Whether it's JS's inheritance mechanism or custom scope behavior or lengthy iterations of coding-compilation. Experienced programmers choose Dart because of the benefits this language provides. These are my personal preferences in the programming language.

Whatever choice you make, do not rate it as final. As a promising developer, you will always learn. Your toolbox will grow. Your first language may affect you, but it will not be the only one.

PS I'm incredibly biased regarding Dart. I can confidently say that my life has changed thanks to Dart. That's because I was one of the first who introduced the language into the workflow, I was in the community from the very beginning, and got such opportunities that would not exist without Dart. I made my contribution to the SDK and documentation at an early stage. I had a chance to get an interview for a position related to Dart, and at the moment I work full time with this language.

Also popular now: