pub trait LazyComponent: 'static {
type Underlying: BaseComponent;
// Required method
fn fetch() -> impl Future<Output = LazyVTable<Self::Underlying>> + Send;
}Expand description
Implement this trait to support lazily loading a component.
Used in conjunction with the Lazy component.
Required Associated Types§
Sourcetype Underlying: BaseComponent
type Underlying: BaseComponent
The component that is lazily being fetched
Required Methods§
Sourcefn fetch() -> impl Future<Output = LazyVTable<Self::Underlying>> + Send
fn fetch() -> impl Future<Output = LazyVTable<Self::Underlying>> + Send
Fetch the component’s impl
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.