Class: Store<T>
Type Parameters
• T
Implements
WritableStore
<T
>Disposable
Constructors
new Store()
new Store<
T
>(value
,eq
?):Store
<T
>
Parameters
• value: T
• eq?
Returns
Store
<T
>
Defined in
lexical-builder/src/Store.ts:14
Properties
__eq()?
optional
__eq: (a
,b
) =>boolean
Parameters
• a: T
• b: T
Returns
boolean
Defined in
lexical-builder/src/Store.ts:13
__listeners
__listeners:
Map
<symbol
,StoreSubscriber
<T
>>
Defined in
lexical-builder/src/Store.ts:12
__value
__value:
T
Defined in
lexical-builder/src/Store.ts:11
Methods
[dispose]()
[dispose]():
void
Returns
void
Implementation of
Disposable.[dispose]
Defined in
lexical-builder/src/Store.ts:30
dispose()
dispose():
void
Returns
void
Defined in
lexical-builder/src/Store.ts:33
get()
get():
T
Returns
T
Implementation of
Defined in
lexical-builder/src/Store.ts:19
set()
set(
value
):void
Parameters
• value: T
Returns
void
Implementation of
Defined in
lexical-builder/src/Store.ts:22
subscribe()
subscribe(
callback
,skipInitialization
): () =>void
Parameters
• callback: StoreSubscriber
<T
>
• skipInitialization: boolean
= false
Returns
Function
Returns
void