Angular 2 RC1 and more announced – ng-conf 2016 recap

Tags: , ,

Well, another ng-conf has come and gone, and this one produced the first official release candidate of Angular 2.0 (RC1).

There were tons of things happening here at the conference, and I know I can't give you a complete rundown, but here are a few big highlights.

The big release – Angular 2.0.0-RC1

Yep, it's live. Angular 2.0, RC1. We've been waiting a year for this, and this means we're getting to less breaking changes, but what else does it mean? Well….

  • Angular 2.0 is now solid enough to build projects from, and there are some big companies that officially announced support for Angular 2 at the conference. Google's own AdWords platform, the big revenue generator, is running it. So is The Weather Channel. Lucid Charts (the web-based charting tool) is on Angular 2. Companies like Capital One and other corporations are beginning to write applications on it. It's real. It may not be 100% complete, but it's here and worth real evaluation.
  • RxJs is at the heart of reactive programming techniques for Angular 2. Anybody doing Angular 2 should really study up on how to make streams of data from Http requests, WebSockets, collections of data, timed events, UI operations, anything that can happen multiple times. The way that streams enable tons of flexible operations (like debouncing input, taking the last 5 entries of something, buffering, filtering, combining two data sources, the list is endless) is going to change the way you code. Count on this as a benefit, with some short-term headaches as you learn how to take advantage of it.
  • The Angular CLI client is live, as of this writing at 0.1.0, and works with Angular 2 RC1. I am running several applications on it, and it handles the gruntwork (pun intended) for you so you don't have to write your own build scripts. You have to be OK with SystemJS over WebPack (that's OK, I find WebPack, to quote someone I know quite well, CornFusing), but it's really here and you can really use it to get stuff done.
  • You're going to want a UI component framework in the near future. At least a wrapper around the CSS stuff. So there are some options emerging, from rolling your own components (they are REALLY easy now compared to writing directives), to Angular 2 Bootstrap, to a very early alpha of Angular 2 Material Design. The latter looks very promising but it's early days at the moment. They used the term 'sometime this year' which tells me it will be a while until feature complete. However, the team had some big goals including graphs, tables, and other advanced widgets, so stay tuned.
  • You are going to want to invest time in learning TypeScript. Here's the thing, folks. One thing Brad Green said, which I agree with, is that TypeScript is JavaScript +. It isn't a different language, it's features added to JavaScript. Many of which will end up in JavaScript in the future (such as annotations, observables, and the like).

    Currently the documentation is sorely lacking for ES5 developers, but a lot of content is available for TypeScript. The IDE plugins for major developer editors, from Vim to Atom to Sublime, to Visual Studio Code, even the JetBrains empire of WebStorm and IntelliJ will all work with minimal fuss with Angular 2 and TypeScript. They'll even provide code completion, refactoring and compiler support. Tooling is the major reason for using TypeScript, and it will help your enterprise development teams become much more productive.

  • On the point of productivity, the Angular CLI has a built-in Angular Style Guide enforcer (see how I snunk in the style guide?) called Codealyzer. It yells at you during compilation of scripts, and also at runtime, when you do bad things, and it even points to the style guide to help you out.

Cool new things

I have a list of things to get to next week that include:

  • Experimenting with the newest NativeScript w/Angular integration project, which lets Angular developers write code in TypeScript that runs native Android and iOS projects that can share much of their code with non-mobile web applications.

  • I also want to mess around with the styleUrls and encapsulation properties in components, which let you control how CSS is embedded in your page. setting encapsulation to ShadowDom lets you actually use the modern Shadow Dom rendering techniques in your application, directly assigning a CSS block to the component itself, where leaving it at the default namespaces your CSS styles so that they won't collide with others.

  • I met up with Chris Thielen, the creator of ui-router, a popular routing API for Angular 1. He told me about the project for integrating the router with Angular 2 – he was updating it to RC1 shortly after we spoke. This project is one way to get lazy loading working in Angular 2 (and even Angular 1) – and it even runs on React as well. Chris is trying to keep the router vendor-neutral, so that you can use it in a number of frameworks. Very interesting approach, and one you might need if you want advanced routing techniques (or "rooting" as the brits called it this week) before the newest Component Router is released.

  • Still have to get WebWorkers running on a project here to see the performance improvements. I'll be writing up a blog entry soon on that technique.

So what's left?

The Angular team had a ton of other ideas but the final straw in the official Angular 2 release's deployment (back) is static compilation. Once this feature ships, they will be feature complete for 2.0 and it's on to more advanced features.

So, goodbye Salt Lake City. I'm gonna miss you, it's been a fun and productive time.

Ken Rimple
May 6 2016