VistianOpenSource/Birch

Layout Optimization

Opened this issue · 0 comments

When the hosts state bag is updated, a complete layout is performed. Whilst the user doesn't see this effort since its moved onto a background thread there may be some room to perform a 'smarter' update.

One possible way could be as follows:

We enhance the layout context to include a 'map' which contains a map between stateful containers and their primitive.

When the initial layout is performed, this map is automatically updated.

When a new stateful change occurs (which should be the only way in which a layout is performed) we can then use the map to try and identify 'where' we should perform an update. This could 'need' a reference to the container '1' up to perform the 'update' .

I suspect this isn't that difficult to achieve, one just needs to tread carefully!