Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

1. What is Dart? > What’s New About Dart?

What’s New About Dart?

Now that you’re all tooled up, let’s talk about the language. We’re not going to go into Dart’s features and syntax in detail—you can read about all of that on www.dartlang.org—but here are a few of the more interesting features of Dart.

Optional typing:  You can use types or not, it’s up to you. Types in Dart code don’t change the way your app executes, but they can help developers and programming tools to understand your code. You might not bother with types while you’re developing a prototype, but you might add types when you’re ready to commit to an implementation. An emerging pattern is to add types to interfaces and method signatures, and omit types inside methods.

Snapshots:  Currently, browsers need to parse a web app’s source code before that app can run. Dart code can be snapshotted—all its state and code recorded at a certain point in time—which can speed up startup considerably. In initial testing, a web app with 54,000 lines of Dart code started up in 640ms without snapshotting. With snapshotting, it started up in 60ms. When your Dart program is running in the Dart VM, it can see significant startup time performance improvements, thanks to snapshots.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint