Material design update 2.0.0-beta.2

So I was happily coding away making changes to my test site where I am learning more about the capabilities of Angular 2 when all of a sudden my automated deployment to Azure gave me a broken page.

The error in the console was:
md-input-container must contain an mdInput directive. 
Did you forget to add mdInput to the native input or textarea element?

This is thought was a bit strange as it was working fine locally on both Mac and PC, but on Azure it was giving me this error.  So I deployed an older build and everything was good again.

The area of concern was this:

<md-input-container>
   <input md-input type="text" class="home-input" id="name" placeholder="name"
       required
       [(ngModel)]="postcode" name="postcode" />
</md-input-container>
After a little digging I found that my CI build on Azure was getting the latest for material2 and therefore was a victim of the latest updates in beta.2:

Breaking changes from beta.1

There are many changes in there and I was a victim of only one :)

For the curious the fix is this:

<md-input-container>
   <input mdInput type="text" class="home-input" id="name" placeholder="name"
       required
       [(ngModel)]="postcode" name="postcode" />
</md-input-container>

Comments

Popular posts from this blog

Kerberos setup for SharePoint 2013

Claims with NTLM and authentication prompts