pub trait SuspenseExtension<T>: Sealed {
// Required method
fn with_loading_placeholder(
self,
display_placeholder: impl FnOnce() -> Element,
) -> Result<T, RenderError>;
}
Expand description
Provides context methods to Result<T, RenderError>
to show loading indicators for suspended results
This trait is sealed and cannot be implemented outside of dioxus-core
Required Methods§
Sourcefn with_loading_placeholder(
self,
display_placeholder: impl FnOnce() -> Element,
) -> Result<T, RenderError>
fn with_loading_placeholder( self, display_placeholder: impl FnOnce() -> Element, ) -> Result<T, RenderError>
Add a loading indicator if the result is suspended
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.