July 2017
Intermediate to advanced
454 pages
10h 1m
English
First of all, we need to install the Angular Material Design package. That is relatively simple using the Angular CLI:
ng new chap10cd chap10npm install --save @angular/material npm install --save @angular/animationsnpm install --save hammerjs
We install two packages here, @angular/material and the hammerjs packages. The first one includes in our app, the Material Design modules, which we will use in the next section. The second package, however, is a JavaScript implementation of touch movements. Some Material Design components such as slider depend on hammerjs.
Then, as per the NgModule specification, we can import MaterialModule as follows:
//src/app/app.module.tsimport { MaterialModule } from '@angular/material'; ...Read now
Unlock full access