aleph-im / aleph-explorer

Simple explorer for the Aleph.im network
4 stars 2 forks source link

Feat: Batch 15 first messages to limit component updates #57

Closed BjrInt closed 1 year ago

BjrInt commented 1 year ago

Enhances the visual look and feel when loading the Homepage for the first time by batching the "QUEUE_SIZE" (number of displayed messages = 15) before updating the message_list component.

Since the previous implementation was done on a naive implementation, this is done at the cost of code readability.

Another caveat of this approach is that, if, for some reason, the API returns less than 15 messages total they will never appear.