Invalid Date from an object

I’m fetching a document from firestore and I could already show it in the console too. This is what the data shows:

displayName: "Person1"
  itemAcquired: t {seconds: 1631084326, nanoseconds: 617000000}
  itemName: "Book1"

[[Prototype]]: Object

I tried displaying the itemAcquired in the screen but it display an “Invalid Date”:

     <Typography>Item Acquired At : </Typography>
               primary={new Date(user.items?.itemAcquired).toLocaleDateString()}


JavaScript Date doesn’t know about firestore timeStamp object, you can use toDate() function along with toDateString()

const date = itemAcquired.toDate().toDateString()

Also you can try

new Date(temAcquired.seconds * 1000).toUTCString()