title: Pipe with ngModel
body: <p>I am applying date pipe on a Input element </p>
  
  <pre><code>&lt;div class="section"&gt;
    &lt;h6 style="font-weight:bold"&gt;From Date&lt;/h6&gt;
      &lt;input [(ngModel)]="Schedule.FromDate | date:'fullDate'" type="text"  class="datepicker"&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>But it did not work , after some searching I found a post on stack overflow and I changed it to </p>
  
  <pre><code>&lt;input [(ngModel)]="Schedule.FromDate | date:'fullDate'" (ngModelChange)="Schedule.FromDate = $event" type="text"  class="datepicker"&gt;
  </code></pre>
  
  <p>Now after adding </p>
  
  <pre><code>(ngModelChange)="Schedule.FromDate = $event"
  </code></pre>
  
  <p>it show error that </p>
  
  <blockquote>
    <p>Uncaught Error: Template parse errors:
    Parser Error: Cannot have a pipe in an action expression at column 21 in [Schedule.FromDate | date:'fullDate'=$event] in ng:///AppModule/UpdateScheduleComponent.html@39:19</p>
  </blockquote>
  
  <p>FromDate is a Date field in Schedule Interface </p>
  
  <pre><code> FromDate: Date;
  </code></pre>
  
  <p>How can I apply pipes on Input element with [(ngModel)]</p>
  
  <p>I am using angular 5 with Material css</p>