Skip to main content

Posts

New site for Dart news and articles

For the latest Dart news, visit our new blog at  https://medium.com/dartlang .

Dart in Education: Interview with Prof. Dr. Nane Kratzke

Nane Kratzke is a professor of Computer Science at the Lübeck University of Applied Sciences  in North Germany. He conducts cloud computing research at the university’s Center of Excellence for Communications, Systems, and Applications (CoSA). He also gives Computer Science courses — one of which uses Dart as a vehicle to teach web programming. We asked Nane about this.   [Off-topic] Is it true you were researching network warfare at some point in your past? Yes, that is true. I was enlisted in German Navy as a Navy Officer and during my military time I studied Computer Science at the University of Federal Armed Forces in Munich, Germany. For about six years after my studies, I was involved as a software engineer, team leader and project leader in several programs for command and control systems of German frigates. After that, I worked as a consulting software architect for a German think tank consulting mainly the German Ministry of Defence. I did some research...

Dart 1.16: Faster tools, updated HTML APIs

Dart 1.16 is now available . This release includes important updates to our tools. Faster developer tools In this release, we've been working closely with our users at Google to make sure Dart is even more productive for developers. We've optimized how Dartium loads applications, improving the time it takes to open an application up to 40%. We also continue to invest in faster code analysis and quicker JavaScript compile times. You should see improved performance in this and future releases. Updated HTML APIs In Dart 1.15 we updated Dartium to Chrome 45 from Chrome 39. In this release, we've updated our browser APIs – dart:html, dart:svg, etc. – to align with these changes. While most of these changes involve new and lesser used APIs, you should verify your application code to find and fix possible breaks. And more... The SDK changelog has details about all of the updates in Dart 1.16 SDK. Get it now .

Unboxing Packages: stream_channel

The stream_channel package is the youngest I’ve written about so far—the first version was published on 28 January 2016, only three months ago as I write this! But despite its youth, it fills a very important role in the Dart ecosystem by providing a common abstraction for two-way communication. In my article on source_span , I wrote about how important it is for a package ecosystem to provide common conventions that can be used throughout the language. stream_channel is another great example of that. The core API it provides is extremely simple, just two getters and a set of rules for them to follow, but the ability for Dart code to implement protocols independent of the underlying implementation is profound. abstract class StreamChannel < T > { Stream < T > get stream ; StreamSink < T > get sink ; } The test package uses StreamChannel to implement a protocol for running tests that works whether the tests are in an isolate, a separate proce...

Unboxing Packages: async Part 3

We’ve covered individual values and we’ve covered streams , but there are still a few more goodies available in the async package. These don’t fit neatly in either bucket, but when you run into situations that call for them, they’re still plenty useful. Wrappers Just like the collection package , async provides a set of wrapper classes. Each of these classes implements a dart:async class and forwards all calls to an inner instance of that class. This makes it easy for users to provide customized versions of those classes. In fact, the async package itself uses some of its own wrappers. There’s a DelegatingFuture class, of course. There’s also a DelegatingStreamSubscription , and wrappers for every kind of sink or consumer you can name: DelegatingSink , DelegatingEventSink , DelegatingStreamConsumer , and of course DelegatingStreamSink . Of these, DelegatingStreamSink is used most often since it encompasses all the functionality of the other classes. /// A [StreamSin...

The new AdWords UI uses Dart — we asked why

Google just announced a re-designed AdWords experience. In case you’re not familiar with AdWords: businesses use it to advertise on google.com and partner websites. Advertising makes up majority of Google’s revenue, so when Google decides to completely redo the customer-facing front end to it, it’s a big deal. The Dart team is proud to say that this new front end is built with Dart and Angular 2. Whenever you asked us whether Google is ‘even using Dart for anything,’ this is what we had in mind but couldn’t say aloud. Until now. We asked Joshy Joseph , the primary technical lead on the project, some questions. Joshy is focusing on things like infrastructure, application latency and development velocity, so he’s the right person to ask about Dart.   Q: What exactly did we launch on Monday? It’s a complete redesign of the AdWords customer experience that is rolling out slowly as a test to a small initial set of advertisers. The most noticeable thing is probably the Material Design ...

Unboxing Packages: async Part 2

Two weeks ago , I introduced you to some of the marvels available for use in the async package. But that package is so big—there are so many marvels—that I couldn’t fit them all in. In fact, I only ended up writing about APIs that deal with futures and the individual values they represent. This week I’ll focus on the other major asynchronous type: Stream . I often find it useful to think of asynchronous types as analogous to synchronous ones, and by that metaphor if futures are individual values then streams are Iterable s. But in addition to representing asynchronously-computed collections of data, streams can represent things like UI events or communication (for example over a WebSocket ). Dart’s Stream class is very powerful. In addition to dispatching events, it allows the user to pause or cancel their subscription to the stream. What’s more, the creator of the stream can be notified of pauses or cancellations (or the initial subscriptions) and take appropriate action—like ...

Dart 1.15: Updated Dartium and improved live code analysis

Dart 1.15 is now available . This release includes important updates to our tools. Updated Dartium version Dartium has been updated from Chrome 39 to Chrome 45. While the underlying browser has been changed, there have been no changes  in this release to the corresponding APIs in dart:html, dart:svg, etc. We will roll out API updates in a future release to maximize stability and ease migration. Improved live code analysis The Dart analyzer service, used by WebStorm, IntelliJ, and Atom has been hardened in 1.15. Using error reports from Dart users within Google, we've been able to eliminate many common sources of instability. You should notice a much more reliable experience within your favorite Dart IDE. Release cadence changes Historically the Dart SDK has released a new stable release roughly every 2-3 months. The release duration has varied from release to release. Going forward we are going to attempt to ship on a more predictable schedule with a new release of ...