I have been trying to create this universal timer for all the users which are login in my app. The app should show the exact timer to all the users irrespective of their time of time. I have been using server timestamp as a starting point and calculating the elapsed time but when the timer 0, it doesn't reset. I am using usestate, useeffect and onsnapshot for this app.
I am using usestate and useeffect to solve th problem but it doesn't work