Leaf
GitHub
Preparing search index...
@muni-town/leaf
encodeClientMessage
Function encodeClientMessage
encodeClientMessage
(
msg
:
|
{
entityId
:
`
leaf:
${
string
}
`
;
type
:
"unsubscribe"
}
|
{
entityId
:
`
leaf:
${
string
}
`
;
snapshot
:
Uint8Array
<
ArrayBufferLike
>
;
type
:
"subscribe"
;
}
|
{
entityId
:
`
leaf:
${
string
}
`
;
type
:
"sendUpdate"
;
update
:
Uint8Array
<
ArrayBufferLike
>
;
}
,
)
:
Uint8Array
Encode a client message to binary.
Parameters
msg
:
|
{
entityId
:
`
leaf:
${
string
}
`
;
type
:
"unsubscribe"
}
|
{
entityId
:
`
leaf:
${
string
}
`
;
snapshot
:
Uint8Array
<
ArrayBufferLike
>
;
type
:
"subscribe"
;
}
|
{
entityId
:
`
leaf:
${
string
}
`
;
type
:
"sendUpdate"
;
update
:
Uint8Array
<
ArrayBufferLike
>
;
}
Returns
Uint8Array
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
GitHub
Leaf
Loading...
Encode a client message to binary.