const dateString = '2020-05-14T04:00:00Z'
I want my output as:
9.10AM 12.07.23
In moment.js I have written as:
<div>{moment(value.col_createddate).format("h.mm A DD.MM.YY")}</div>
But now I want in dayjs.
const dateString = '2020-05-14T04:00:00Z'
I want my output as:
9.10AM 12.07.23
In moment.js I have written as:
<div>{moment(value.col_createddate).format("h.mm A DD.MM.YY")}</div>
But now I want in dayjs.
Copyright © 2021 Jogjafile Inc.
In Day.js, you can achieve the desired output using the format method, similar to how you would in Moment.js. Here's how you can format the given dateString using Day.js:
This code uses Day.js to parse the dateString and then formats it according to your specified format: "h.mmA DD.MM.YY". The format method in Day.js works similarly to Moment.js for formatting dates.