Angular 2.0

Saw this post from the Angular team about Angular 2.0 and figured it would be worth while to share with everyone about their plans for 2.0 and beyond. Looks really interesting especially the part about being written in ES6 and how they want to simplify dependency injections.

Enjoy

2 Likes

Love this part

Angular 2 is a framework for mobile apps.

Agreed!

Also the part where they mention Ionic and Cordova.

Am I correct in saying that supporting native API access (through standard and/or Ionic-made Cordova plugins) is also one of the goals of Ionic? I think I read that somewhere around hereā€¦

I remember a tweet or blog post from one of the guys about extend Cordova plugins too. But any plugins that would be made are still built on top of Cordova, so the two go hand in hand.

Any further thoughts after more information is coming to light?.. http://www.infoq.com/news/2014/10/angular-2-atscript

Particularly in light of this:

"Developers had mixed feelings about the massive change. On Hacker News, user zak_mc_kracken said:

ā€˜Even though this is still called ā€œAngularā€, this new version has barely any resemblance with the previous one, itā€™s really a totally new framework. Itā€™s a bit sad to think that all this knowledge I have of Angular 1 is now obsolete but Iā€™m excited to dive into this new framework. If itā€™s half [as] revolutionary as Angular 1 was, itā€™s going to be a pretty interesting time.ā€™"

It sounds almost as if angular is having an ā€œoauth momentā€ā€¦ http://hueniverse.com/2012/07/26/oauth-2-0-and-the-road-to-hell/

I think a great way to think about things is that Angular 2.0 is going to do more with pure javascript than before. Which I am excited for as well. This way, people donā€™t have to learn the ā€œangular wayā€ of doing things, but can start to get back to thinking in plain javascript. Definitely a big win for all of us.

1 Like

Is there any reason to be concerned about using Ionic on a new project now? I.e. a year from now, when this new AngularJS is released, what will the impact be on Ionic (if any)? (Iā€™m a newcomer to both AngularJS and Ionic.) Thanks.

Ionic will probably have to be completely re-written when 2.0 comes out. Nearly every API is changing.

I was just about to begin writing an Ionic application, which will be updated next year, 2015 Q3, and probably would like to use Angular 2.0 for that. Any official statements on aligning Ionic with Angular 2.0?

Good thing is that 2.0 wonā€™t be out for a while so no need to worry too much.

Weā€™ve been in close contact with the angular team and have started to prepare ionic for the migration. A big win for us is that we use raw JS inside of our controllers and donā€™t rely heavily on angular functionality. Yes there were will be some things that we have to rewrite, but it will give the devs a chance to implement the lessons learned over the past year.

Since we work with the angular team on Angular Material, they have been in contact with us about testing out 2.0 when it is ready. They have been very proactive about working with us to make sure 2.0 has the tools it needs for Ionic, such as the new routing system and animations. Rest assured that the lessons learned from Ionic and Material will be applied to Angular 2.0, and material will begin to find its way into Ionic.

8 Likes

This is just my opinion/perspective, as a developer using Angular for over 2 years, and from general open source developer perspective.

Open source release timelines are never guaranteed. The Angular team and community will take as long as it takes to build it the right way, and I prefer that over fixing a date and rushing to meet it. The road from 0.9 to 1.0 was almost two years, because of real world usage of the framework gave very important feedback that became incorporated into Angular. The plans for Angular 2 are ambitious, and in many ways will have to go through a similar process of trial by fire to establish best practices and framework design. Its going to take time to nail down the right APIs even if they have the foundations planned now, and since Angular 2 is full of a lot of major changes, its not just a matter of making a few changes to the current 1.x branches. I doubt many of us can delay our business decisions based on the estimated and not guaranteed estimates of a new framework release, not even including the time it takes to learn the new version.

As a developer I urge you not to let the future impair your ability to develop and release something in the present.

Indications are that Angular 2.0 is not going to be an upgrade to implement, it will be a migration or major refactoring. With that in mind, The 1.x branch will likely remain in force for some time and not require immediate changes to existing applications. Any code is subject to laws of maintenance, and Ionic will also require some changes. As Iā€™m digging into the depths of Ionicā€™s source code, you can know that its pretty well structured and organized. Many aspects are abstracted outside of Angular, so I donā€™t think we will need a full rewrite. The real challenge is likely to be how to best build with Angular 2, and then mold Ionic to fit into that paradigm.

6 Likes

thank you Mike and gnomeontherun! These are good news!

Just to give you guys the chill : http://angularjs.blogspot.fr/2015/03/announcements-from-ng-conf-were.html

Still chilling

Looks SO awesome ^^

Will Ionic plan to support Angular 2.0 and Nativescript?
I think it will be great for cross platform development.

We will support Angular 2.

NativeScript has direct access to native platform APIs using JavaScript VMs that contain a bunch of APIs which let you configure the JavaScript environment --> theoretically will have much better performance (I donā€™t know, at the moment I am a satisfied Ionic user)

Cordova has direct access to device apiā€™s through javascript as well.
Weā€™re not planning on jumping to a different technology, but helping out where we can to improve the platform.

Are there any guides out there for Ionic 1.0 best practices (to help with future Ionic 2.0 migration)?

Based on what Iā€™ve gathered from other blogs about Angular 2 migration that I think could be beneficial for Ionic would be:

  • Removing dependencies on $scope
  • Create thinner controllers (move logic to services)
  • Bind controllers to directives

All of that is super useful for angular 2 migration.
For anything involving Ionic, canā€™t share too much on thatā€¦no solid code to test against :smile:
But one can expect that if you follow these best practices, it will help you when ionic 2 comes out.

Check out this video if you want to see some more angular 2 code.