I have a service that obtains certain data from a BehaviorSubject.
this.myData.album$.value.album_date;
When console logging the returned date from firestore with:
console.log(this.myData.album$.value.album_date);
The console reads:
Timestamp {seconds: 1572263054, nanoseconds: 63000000}
What I need to do is convert this value inside one of my functions and manipulate it into any format, such as "Monday, 28th October 2019".
Unfortunately given my requirement i cannot use the toDate() |
inside the HTML and this needs to be achieved within my function.
Any assistance here would be greatly appreciated.
Note: I have moment
available to use within my Typescript file.
I am using Angular 8
and Firestore