'Firebase AsyncSnapshot, length of documents?

I need the length of Firebase documents for my app to make a ListView of them, but for some reason the data.docs cannot be found, even though the official Firebase website says it should (https://firebase.flutter.dev/docs/firestore-odm/references/). I tried everything, using documents keyword instead, using snapshot.requireData, but nothing is working. What am I doing wrong here?

enter image description here



Solution 1:[1]

enter image description here

use this way

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Furkan ?im?ek