Reputation: 83
Currently I am displaying the dateZone of IST and I need to display the datezone according to the users location.
app.component.html:
<td>{{scan.createdOn + 'Z' | date :'medium'}}</td>
Upvotes: 1
Views: 158
Reputation: 18095
You can use a localized date pipe for that.
{{ value_expression | date [ : format [ : timezone [ : locale ] ] ] }}
Please check the i18n guide of the official Angular documentation here for more info: https://angular.io/guide/i18n-common-format-data-locale
Upvotes: 1