[Vuejs]-How can I display elements that are not outdated with Vue.js and firebase?

0👍

This depends a bit on the definition of when a node expires. If you store the timestamp of when a child node becomes outdated, e.g.

child.expires = Date.now();

Then you can query for nodes that haven’t expired with:

firebase.database().ref('events').orderByChild('expires').startAt(Date.now()).once('value')
  .then((data) => {
    ...

Leave a comment