I need to show a countdown timer on a screen. Since I am using bloc elsewhere in the App, I thought it could be good idea to use bloc to update the watch display in the presentation layer using a bloc. Has anyone done this before? Some specific questions I have are
How do I dispatch an event on every tick of the clock? I need it down to a second level.
Will it be too much for a bloc to process?
What kind of delay should I expect in the actual display of the timer in the presentation layer due to added processing in the bloc? I am talking about granularity down to a second. If the bloc takes even 100ms to process, there is going to be 10% error which is huge. In that case, it would be good to be able to adjust the lag, say, every 10th second or so.
I need to show a countdown timer on a screen. Since I am using bloc elsewhere in the App, I thought it could be good idea to use bloc to update the watch display in the presentation layer using a bloc. Has anyone done this before? Some specific questions I have are