Home > Blockchain >  DataSnapshot.getChildrenCount has error "The getter 'getChildrenCount' isn't def
DataSnapshot.getChildrenCount has error "The getter 'getChildrenCount' isn't def

Time:05-19

I am trying to get a count of how many children are in a path. I could not find anyone else with this problem.

CodePudding user response:

The getChildrenCount() method is part of the Android SDK for Firebase Realtime Database. But since you tagged with Flutter, you are likely looking for snapshot.children.length. Also see the reference docs for the DataSnapshot class.

  • Related