简体   繁体   中英

How can I create a live user count on my firebase and flutter app?

I want to include a text box on my app that displays how many users are currently on the app (concurrent users). I'm using Firebase and flutter and I'm wondering if anyone has any suggestions. I know firebase reports the amount of live users for analytics, but is there a way to take that data and show it to the users?

我会为每个用户使用像这里这样的presence状态观察器的组合,并将在线状态保存在数据库和一个简单的云函数中,该函数侦听更改并增加或减少总计数器。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM