last time I told you about a handy Flux feature: you can handle the asyncronous code as sync one. So before we begin, I’ll describe the issue:
- there is a big table, let it be 10k x 10k cells;
- it’s possible to show only 10 x 10 cells on screen at once.
- User can navigate in any direction of that big data canvas;
- we can ask the server for a brief version of data (request takes <500ms);
the full metadata package for 10 x 10 cells area is downloaded in 1.5-2s.
So once the user finished the navigation, we need to show at least something quickly then be ready to show all the metadata. Behind the UX we have to do two requests and handle the data respectively. How this could be done in Flux?