Interface: UseAwarenessResult
@roomful/react / UseAwarenessResult
Interface: UseAwarenessResult
Section titled “Interface: UseAwarenessResult”Defined in: react/src/index.ts:155
Describes the return value of useAwareness.
Properties
Section titled “Properties”others
Section titled “others”others:
AwarenessState[]
Defined in: react/src/index.ts:159
Exposes remote awareness state only.
set: (
value) =>void
Defined in: react/src/index.ts:164
Merges arbitrary awareness metadata into the local peer.
Merges arbitrary awareness metadata into the local peer.
Parameters
Section titled “Parameters”Record<string, unknown>
The awareness fields to merge.
Returns
Section titled “Returns”void
Nothing.
setFocus()
Section titled “setFocus()”setFocus: (
elementId) =>void
Defined in: react/src/index.ts:169
Updates the local focus target.
Updates the local focus target.
Parameters
Section titled “Parameters”elementId
Section titled “elementId”The focused element identifier, or null to clear it.
string | null
Returns
Section titled “Returns”void
Nothing.
setSelection()
Section titled “setSelection()”setSelection: (
selection) =>void
Defined in: react/src/index.ts:174
Updates the local selection.
Updates the local text selection.
Parameters
Section titled “Parameters”selection
Section titled “selection”The active selection, or null to clear it.
AwarenessSelection | null
Returns
Section titled “Returns”void
Nothing.
setTyping()
Section titled “setTyping()”setTyping: (
isTyping) =>void
Defined in: react/src/index.ts:179
Updates the local typing state.
Updates the local typing state.
Parameters
Section titled “Parameters”isTyping
Section titled “isTyping”boolean
Whether the local peer is currently typing.
Returns
Section titled “Returns”void
Nothing.