title: Implement realtime online/offline status with flutter and firebase
body: <p>Hy, what is the best way to show in an app if the user is online or offline? </p>
  
  <p>Frontend -> Flutter</p>
  
  <p>Backend -> Firestore Cloud and Firebase Auth.</p>
  
  <p>I have a collection of users in firestore that contains documents. Each document is a user and contain "status" field. In flutter i can update this field every time that user sign in or log out but if you close the app it is not updated.</p>