Now that smol returns the same Task as async_task, we can simply re-export the async_task::Task struct from our executor module.
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Now the Element trait is designed to be wrapped in a Lifecycle enum that gets placed inside an ElementBox. This allows the framework to store data on behalf of the Element implementation, such as sizes, bounds, and also implementation-specific LayoutState and PaintState types. This makes it easier to reason about which data is available in each Element method.
Also, eliminate the background spawning methods. We can spawn futures
on the executor and then spawn those on the app if we need to wait for
the result of running one.