我正在使用firebaseAnimatedList显示firebase数据库记录,但是仅显示3条记录中的2条记录。请帮助解决此问题。
此处带有显示正文的代码。 小部件_showBody(){ 返回列( mainAxisAlignment:MainAxisAlignment.start, crossAxisAlignment:CrossAxisAlignment.stretch, 孩子:[
Container(
child: Flexible(
child: FirebaseAnimatedList(
query: databaseReference,
itemBuilder: (_, DataSnapshot snapshot,
Animation<double> animation, int index) {
return new Card(
color: Colors.brown,
child: ListTile(
title: Text(shopList[index].shopName),
subtitle: Text(shopList[index].address),
),
);
},
),
),
),
],
);
}