Async UIs - miguelperezcolom/mateu GitHub Wiki
Some times you want some parts of your UI to be loaded asynchronously instead of the whole page waiting for all the needed data to be gathered before rendering the page. E.g. you want a label, a table or any other component in the UI to be rendered after you get the answer to an specific http call which is independent of the http call you issued for getting the main UI content.
Some times you want to keep listening to events thrown from the backend to continuously update the UI (or part of it). E.g. you made a call to a long background process and you want to show in the UI the progress of that task as it runs, or you want to implement a chat like behavior.
So it's not only the user who initiates an interaction with the backend by clicking on a button and, subsequently, the UI is updated. Instead, the UI (or parts of it) can be updated as a consequence of receiving some new data from the backend, e.g using websockets or server sent events (SSE). This behaviour is already happening when you open a CRUD where the list data is received asynchronously in a different http call than the one which was issued for getting the CRUD structure.
As per today only 3 kind of async components are supported:
- badges (url or callable as value) (pass the whole data to hydrate the container) class implementing a ValueProvider interface
- Callable fields in forms (pass the whole data to hydrate the container)
- RemoteJourney for whole components
TBD