React Native and Zustand Real-time data
Hey everyone,
I am writing a react native app that uses mqtt for real time data comms, and needs to be able to update every 100ms if possible.
I am using zustand to handle the mqtt data outside of the react tree to help reduce uneccessary renders.
I timed this function using new Date().getTime() before and after, and it it seems to be taking ~600ms to call the function.... which doesnt seem right
1 Reply
using get and clearing seemd to fix it
the issue is, if i dont call a set function... then my ui never updates
but the zustand set function takes ~600ms
š