I'm looking for a way to do an 'elapsed time' for the frontend of a messaging application (in Quasar) so that the messages come out like for example "Sent by Jaimito 5 minutes ago".
Investigate and find that the timeago
component exists and try to follow the instructions of link but the closest thing to what I could get was to import the component in a way similar to this:
import VueTimeago from 'vue-timeago'
export default {
name: 'PageIndex'
,created() {
this.time = Date.now()
}
,components: {
'timeago': VueTimeago
}
}
And to use it within the html of the form:
<timeago :since="time"></timeago>
Neither has served me with:
<timeago :datetime="datetime"></timeago>
As for the error does not come out, nothing just appears.
I am running it in a Quasar page in a SPA