How to use angular material (https://material.angularjs.org) in Angular 2 Apps?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP



How to use angular material (https://material.angularjs.org) in Angular 2 Apps?



I remember having seen angular-material.css being used in one of the Angular 2 Demos at ng-conf. Can someone confirm if this works...



Also, is it possible to use the following in Angular 2 Apps:



I know that above js have a dependency on Angular 1.3+, but what if I add that dependency over and above my Angular 2 dependency. Will these work then?




2 Answers
2



So currently you cannot use the current angular material with angular2.



According to Marcy Sutton, they will be addressing incorporation of Angular Material once the team has realeased 1.x.



https://github.com/angular/material2 is the new repo that will be compatible with ng2. There are some forks of Material that may work with ng2 already such as ng2-material.



No, Angular Material 1.x does not support Angular 2+. You can see some of the issues and discussion around this in issue #6336. Basically, many of the existing, tested components would need to be re-written (many months of work).



material2 only recently (Dec 2016) entered beta and may not be ready for all production applications. If you need Material Design for your Angular 2 app ASAP, then contributing to material2 is your best option.



As far as I know, there is no Material Design library that is production ready (out of beta) for Angular 2+.



I was using Angular2-Polymer with Polymer paper elements to get Material Design in my Angular 2+ applications, but breaking changes in Angular 2.2 have broken that integration and may require a significant re-write of the lib.



Material Components for the Web may someday be another option, but they are in alpha atm.






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Firebase Auth - with Email and Password - Check user already registered

Dynamically update html content plain JS

Creating a leaderboard in HTML/JS