IdentifiedComponentWrapper
public struct IdentifiedComponentWrapper<ID, Wrapped> : ComponentWrapping, IdentifiableComponent where ID : Hashable, Wrapped : Component
A wrapper around the compoent to conform to IdentifiableComponent.
-
A type that represents an id that used to uniquely identify the component.
Declaration
Swift
public var id: ID -
The wrapped component instance.
Declaration
Swift
public var wrapped: Wrapped -
Create a component wrapper wrapping given id and component.
Declaration
Swift
@inlinable public init(id: ID, wrapped: Wrapped)Parameters
idAn identifier to be wrapped.
wrappedA compoennt instance to be wrapped.
View on GitHub
IdentifiedComponentWrapper Structure Reference