Interface IClientConfig

Hierarchy

Index

Properties

Properties

optional public assembleFragments?: boolean

If true, fragmented messages will be automatically assembled and the full message will be emitted via a message event. If false, each frame will be emitted on the connection object via a frame event and the application will be responsible for aggregating multiple fragmented frames. Single-frame messages will emit a message event in addition to the frame event.

default

true

optional public closeTimeout?: number

The number of milliseconds to wait after sending a close frame for an acknowledgement to come back before giving up and just closing the socket.

default

5000

optional public fragmentOutgoingMessages?: boolean

Whether or not to fragment outgoing messages. If true, messages will be automatically fragmented into chunks of up to fragmentationThreshold bytes.

default

true

optional public fragmentationThreshold?: number

The maximum size of a frame in bytes before it is automatically fragmented.

default

16KiB

optional public maxReceivedFrameSize?: number

The maximum allowed received frame size in bytes. Single frame messages will also be limited to this maximum.

default

1MiB

optional public maxReceivedMessageSize?: number

The maximum allowed aggregate message size (for fragmented messages) in bytes.

default

8MiB

optional public webSocketVersion?: number

Which version of the WebSocket protocol to use when making the connection. Currently supported values are 8 and 13. This option will be removed once the protocol is finalized by the IETF It is only available to ease the transition through the intermediate draft protocol versions. The only thing this affects the name of the Origin header.

default

13