Using Object Pooling with UseRef to Prevent GC with UseState
I was pondering on the idea of using object pooling to store time series data that is updated every 10mins.
I have a slight concern that if i stored the data in useState it would cause a lot of GC overtime - my presumtion here is that on each update of the UseState it creates a new object of the data that the GC will have to clean up.
Would using a UseRef to store the obeject pool be a sensiable idea or is this to put it politely a dumb idea
0 comments
[ 3.2 ms ] story [ 12.4 ms ] threadNo comments yet.