DateTime in custom HTML


#1

I have a problem with adding a DateTime component to my app prototype. I don’t know any AngularJS (yet), so I also have trouble with directives.

I studied this page and other posts related to this, but couldn’t figure out how to do this in Creator. I copied this code to my custom HTML component:

<ion-item>
  <ion-label>Date</ion-label>
  <ion-datetime displayFormat="MM/YYYY" pickerFormat="MMMM YYYY" [(ngModel)]="myDate"></ion-datetime>
</ion-item>

All I see in preview is the item and label, but no datetime. I’m aware that I should do something with ngModel, but I didn’t find any information about how to use it in a similar case. Any advice?

I’m sorry this such an easy question, but I’m just getting started with Ionic so any help would be greatly appreciated.