Holen Sie sich alle Daten in der Sammlung Firebase React

 const [driverBookings, setdriverBookings] = useState([]);
  useEffect(() => {
    db.collection("driverBookings").onSnapshot((snapshot) => {
      let driverBooking = snapshot.docs.map((doc) => ({
        ...doc.data(),
        id: doc.id,
      }));

      setdriverBookings((prev) => [...prev, ...driverBooking]);
    });
Niraj Kafle