📜 ⬆️ ⬇️

Do I need a dart?

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 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, polling and managing remote equipment and storing the results in the database, on the basis of which you could then get beautiful graphics.

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

Javascript can do the same thing as Dart. And JS has an advantage in the number of ready-made libraries. I would advise them to avoid when learning JS, the use of libraries by beginners can lead to the fact that a potential programmer will know how to write on jQuery, but not like JS, and ultimately to the poor performance of developed sites. I have already had the opportunity to correct 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, this is no longer such a big problem as it was when Dart just came out). The functionality of standard libraries in Dart gives such features that are not found 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 unpredictable ways.
')
With Dart, conflicts are easier. Firstly, the libraries themselves are smaller, and secondly there are standard mechanisms for avoiding conflicts. Fewer libraries have their advantages, for example, you need to consider fewer different options to find the one that suits your project.

And the decisive factor that will influence the decision whether Dart is worth your time is a community of developers. JS has long been gathering people around it, the Internet is filled with lessons, forums, examples, and most importantly 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 cannot cope with the first difficulties in learning and throw language.

Due to the fact that the Dart community is smaller, and due to the fact that its followers are more experienced, there are fewer lessons and, in particular, fewer lessons that are aimed at newcomers to programming. There are books and articles, but their number is negligible compared to JS. This disadvantage is balanced by the fact that the Dart community is extremely loyal to its language and propagandizes it in every possible way. Of all the communities that I have met, the Dart community is the most open and hospitable.

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 is the mechanism of inheritance in JS or non-standard behavior of the scope or long iterations of coding-compilation. Experienced programmers choose Dart because of the advantages provided by this language. These are my personal preferences in a programming language.

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

PS I am incredibly addicted regarding Dart. I can say with confidence that my life has changed thanks to Dart. That's because I was one of the first to introduce the language into the workflow, I was in the community from its very beginning, and got opportunities that would not have been 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.

Source: https://habr.com/ru/post/269209/


All Articles