NeoLegends / velocity-pwa

🚴‍♂️💨 An alternative https://velocity-aachen.de/menu
3 stars 3 forks source link

Throw promises in hooks to trigger suspense #4

Closed NeoLegends closed 5 years ago

NeoLegends commented 5 years ago

Right now we have content flashes when the page itself has loaded, but the contents have not. If we make the hooks throw promises (which triggers suspense), React will only show the page when all of the contents have loaded.

NeoLegends commented 5 years ago

We might want to wait until React itself provides a proper solution here. They announced they would provide one in the near future.

NeoLegends commented 5 years ago

This is mostly blocked on React releasing suspense for data fetching. Closing because the app works rather fine in practice. We can come back to this later once React delivers.