flutter count list irem visile code example
Example: flutter count list
var comments = <Comment>[...];
var count = comments.where((c) => c.product_id == someProductId).toList().length;
var comments = <Comment>[...];
var count = comments.where((c) => c.product_id == someProductId).toList().length;