date format pipe in angular 6 code example
Example 1: angular date pipe
// In Angular
// Html
<p>{{myDate | date: 'dd-MM-yyyy'}}</p>
// Typescript
myDate: Date = new Date();
Example 2: applying datepipe on interepolating date in html from typescipt
tooltip="{{recentDate | date: 'medium'}}" // Using interpolation