0

I am getting the data from API as childDob: "23/10/2019" how to show this in .html here is my frontend code is

<input type="date" [(ngModel)]="allUpdate.childDob" required>

How to do this? Any help.

1 Answer 1

1

You can try with date pipe like :

<input type="date" [(ngModel)]="allUpdate.childDob | date: 'M/d/yy'" required>

For more details : https://angular.io/api/common/DatePipe

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.