new date in interpolation angular

Solutions on MaxInterview for new date in interpolation angular by the best coders in the world

we are a community of more than 2 million smartest coders
registration for
employee referral programs
are now open
get referred to google, amazon, flipkart and more
register now
  
pinned-register now
showing results for - "new date in interpolation angular"
Agatha
12 Aug 2017
1// create a method in .ts file
2convertDate(date){
3  return new Date(date+' UTC');//convert UTC time to Local time
4}
5
6//call the above function from .html file
7{{convertDate(item.CreatedOn) | date:'medium'}}