Chapter 1. Getting Started with Dart

The first chapter will introduce us to the world of Dart. We'll learn:

  • What is so interesting about Dart and why it's worth your time to give it a try
  • Where and how to get the Dart SDK with its IDE called Dart Editor
  • How to create the first app and see how to run and debug it in Dartium
  • How to compile our app to JavaScript

What is Dart?

The Dart language was first unveiled at the GOTO conference in Aarhus in October 2011. Its primary goal, in the long run, is to replace JavaScript as the only language in browsers.

Although JavaScript is very easy to use for smaller apps, with the increasing complexity and the necessity to scale today's projects, it quickly becomes very hard to maintain. Frankly, JavaScript wasn't designed for this and writing larger apps is just a pain.

Dart was created as a brand new language with C-style syntax; it's object-oriented and class-based with a single inheritance model with mixins. It gives you many things that you've probably already used in other languages, such as abstract classes, encapsulation, reflection, exceptions, and so on. On the top of that, you can make use of optional static type checking.

Then, if you look a little deeper, you'll find things such as Future-Based API for all asynchronous calls, typedefs, isolates, streams, zones, dependency management, and even more out of the box. You'll probably find many of these things already familiar, but as you'll see, Dart uses a very easy-to-understand approach, which allows you to stay focused on writing your apps instead of dealing with the language itself.

In November 2013, Dart reached its first stable release, 1.0, and is still in active development.

On March 23, 2015, the Dart team released version 1.9, which significantly simplified working with asynchronous APIs and is considered the most important release since version 1.0.

At the end of April 2015, Google held the first Dart Summit revealing plans to use Dart as a language for cross-platform mobile development with their new runtime called Fletch.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.145.35.194