Hierarchy Step 19

This lesson is only available for PRO members. Sign-in and choose a plan below.

Monthly

$25/month
  • Unlimited course access
  • Cancel anytime
  • Slack #pro-member invite
  • AngularFirebase Survival Guide Book

Quarterly

$50/3mo
  • All monthly tier benefits
  • 33.33% discount
  • 🔥 Free Sticker

Lifetime

$300/one-time
  • All monthly tier Benefits
  • One-time payment
  • 🔥 Free sticker & 👔 T-Shirt

file_type_js_official firestore.js
const topLevel = db.collection('comments').where('parent', '==', false);


const level = db.collection('comments').where('parent', '==', id)


const traverseAll = (id) => {
    const tree = db.collection('comments')
    .where('parent', '>=', id)
    .where('parent', '<=', `${id}~`)
}

Q&A Chat