What’s Next

As mentioned in Chapter 7, Classes and Objects, Dart frowns on dynamic language features that are necessary for metaprogramming. Even so, it is quite possible to achieve some pretty nifty dynamic language features in Dart. The noSuchMethod method is certainly an easy one to hook into for a significant portion of metaprogramming. It is limited to instance methods, but this ought to cover 80 percent of a developer’s dynamic programming needs. When that fails, there are still ways to exploit Dart’s functional nature to achieve broader dynamic language features. And we have not even mentioned Dart’s reflection capabilities, which are already used heavily in projects like Angular.dart.

With a pretty intense code organization project ...

Get Dart 1 for Everyone now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.