I have the following code to show the current date:
this.whatTime = Observable.interval(1000).map(x => new Date()).share();
And in my te
You should use this:
import moment from 'moment';
Then you should call it like that:
moment(timestamp).fromNow();
This will give you the current time.