libp2p
    Preparing search index...

    An object that contains an AbortSignal as the optional signal property.

    const controller = new AbortController()

    aLongRunningOperation({
    signal: controller.signal
    })

    // later

    controller.abort
    interface MultistreamSelectInit {
        lengthDecoder?: (data: Uint8ArrayList) => number;
        lengthEncoder?: (
            value: number,
        ) => Uint8Array<ArrayBufferLike> | Uint8ArrayList;
        maxBufferSize?: number;
        maxDataLength?: number;
        maxLengthLength?: number;
        negotiateFully?: boolean;
        signal?: AbortSignal;
    }

    Hierarchy (View Summary)

    Index

    Properties

    lengthDecoder?: (data: Uint8ArrayList) => number
    lengthEncoder?: (value: number) => Uint8Array<ArrayBufferLike> | Uint8ArrayList
    maxBufferSize?: number

    Incoming bytes are buffered until read, this setting limits how many bytes will be buffered.

    4_194_304
    
    maxDataLength?: number
    maxLengthLength?: number
    negotiateFully?: boolean

    When false, and only a single protocol is being negotiated, use optimistic select to send both the protocol name and the first data buffer in the initial message, saving a round trip for connection establishment.

    true
    
    signal?: AbortSignal