@latticexyz/recs / ComponentWithStream
#
Interface: ComponentWithStream<S, T>
Type of component returned by defineComponent.
#
Type parameters
#
Hierarchy
#
Table of contents
#
Properties
entities id metadata schema stream$ update$ values world
#
Properties
#
entities
• entities: () => IterableIterator
<EntityIndex
>
#
Type declaration
▸ (): IterableIterator
<EntityIndex
>
#
Returns
IterableIterator
<EntityIndex
>
#
Inherited from
#
Defined in
#
id
• id: string
#
Inherited from
#
Defined in
#
metadata
• metadata: Metadata
#
Inherited from
#
Defined in
#
schema
• schema: S
#
Inherited from
#
Defined in
#
stream$
• stream$: Subject
<{ entity
: EntityIndex
; value
: undefined
| ComponentValue
<S
, T
> }>
#
Defined in
#
update$
• update$: Subject
<ComponentUpdate
<S
, T
>> & { observers
: any
}
#
Inherited from
#
Defined in
#
values
• values: { [key in string | number | symbol]: Map<EntityIndex, ValueType<T>[S[key]]> }
#
Inherited from
#
Defined in
#
world
• world: World