How to use the rxfire/firestore.collectionData function in rxfire

To help you get started, we’ve selected a few rxfire examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github AngularFirebase / 131-rxfire-stencil-todos / src / components / my-component / my-component.tsx View on Github external
switchMap(user => {
          // Define the query
          if (user) {
            const query = this.ref.where('user', '==', user.uid);
            return collectionData(query, 'taskId');
          } else {
            return [];
          }
        })
      )
github CreativeBuilds / creative-bot / src / renderer / helpers / rxUsers.ts View on Github external
(user): ObservableInput => {
      if (!user) {
        return [];
      }

      const firestoreReference = firestore
        .collection('users')
        .doc(user.uid)
        .collection('users');

      return collectionData(firestoreReference);
    }
  ),
github CreativeBuilds / creative-bot / src / renderer / helpers / db / db.ts View on Github external
(user): ObservableInput => {
      if (!user) {
        return [];
      }

      const firestoreReference = firestore
        .collection('users')
        .doc(user.uid)
        .collection('users');

      return collectionData(firestoreReference);
    }
  ),
github jsayol / FireSQL / src / rx / index.ts View on Github external
queries.map(query =>
      collectionData(query, idField)
    )
github CreativeBuilds / creative-bot / src / renderer / helpers / rxCommands.ts View on Github external
(authUser): ObservableInput => {
      if (!authUser) {
        return empty();
      }
      const ref = firestore
        .collection('users')
        .doc(authUser.uid)
        .collection('commands');

      return collectionData(ref);
    }
  ),
github FirebaseExtended / reactfire / reactfire / firestore / index.tsx View on Github external
export function useFirestoreCollectionData(
  query: firestore.Query,
  options?: ReactFireOptions
): T[] {
  const queryId = getHashFromFirestoreQuery(query);

  return useObservable(
    collectionData(query, checkIdField(options)),
    queryId,
    checkStartWithValue(options)
  );
}
github CreativeBuilds / creative-bot / src / renderer / helpers / rxCustomVariables.ts View on Github external
(authUser): ObservableInput => {
      if (!authUser) {
        return empty();
      }

      const ref = firestore
        .collection('configs')
        .doc(authUser.uid)
        .collection('custom_variables');

      return collectionData(ref);
    }
  ),
github CreativeBuilds / creative-bot / src / renderer / helpers / rxTimers.ts View on Github external
(authUser): ObservableInput => {
      if (!authUser) {
        return empty();
      }
      const ref = firestore
        .collection('users')
        .doc(authUser.uid)
        .collection('timers');

      return collectionData(ref);
    }
  ),
github CreativeBuilds / creative-bot / src / renderer / helpers / rxEmote.ts View on Github external
(authUser): ObservableInput => {
        if (!authUser) {
          return empty();
        }
        const ref = firestore
          .collection('users')
          .doc(authUser.uid)
          .collection('emotes');
  
        return collectionData(ref);
      }
    ),