Material angular, md vs mat , @angular/material@2.0.0-beta.11 template parse errors

Viewed 3821

I've just updated angular material via NPM (@angular/material@2.0.0-beta.11-53c42a4)

Now my apps doesn't work anymore, because syntax differences. I look up the documents what's changed, but there isn't much information out there about this issues.
I've tried to replace all the

import{ Md ** Module, etc. } from "@angular/material"
with
import {Mat ** Module} from "@angular/material" in app.module file.

I've still got Template parse errors. An example of many errors I've got

My question is: Where do I begin to solve this problem?

I was planning to :
1) Change all the import Md ** Module -> Mat ** Module
2) Try to trial and error change all the HTML tags


Update: Through trial and errors I've solved partial of this question. What I did is following:

  1. change all the import{ Md ** Module, etc. } from "@angular/material" into
    import {Mat ** Module,etc.} from "@angular/material"
  2. Go through all the *.html files of the components and changed the HTML-tags.
    <md-expansion-panel></md-expansion-panel> <md-select><md-option></md-option></md-select>... etc
    into
    <mat-expansion-panel></mat-expansion-panel> <mat-select><mat-option></mat-option></mat-select> ...etc.
    The prefix md is changed into mat. I think there's no easy way to solve this.
0 Answers
Related