ISharedCounter Interface
Packages > @fluidframework/counter > ISharedCounter
Shared counter interface
Signature:
export interface ISharedCounter extends ISharedObject<ISharedCounterEvents>
Extends: ISharedObject<ISharedCounterEvents>
Properties
Property | Type | Description |
---|---|---|
value | number | The counter value. |
Methods
Method | Description |
---|---|
increment(incrementAmount) | Increments or decrements the value. Must only increment or decrement by a whole number value. |
Events
value
The counter value.
Signature:
value: number;
Methods
increment
Increments or decrements the value. Must only increment or decrement by a whole number value.
Signature:
increment(incrementAmount: number): void;
Parameters
Parameter | Type | Description |
---|---|---|
incrementAmount | number | a whole number to increment or decrement by |
Returns:
void