Logos DX
    Preparing search index...

    Interface CookiePlugin<H, P, S>

    Return shape of cookiePlugin() — a FetchPlugin augmented with jar access, adapter lifecycle methods, and a graceful shutdown flush().

    interface CookiePlugin<H = unknown, P = unknown, S = unknown> {
        hooks?: HookEngine<any, [string]>;
        jar: CookieJar;
        name: string;
        flush(): Promise<void>;
        init(): Promise<void>;
        install(engine: FetchEnginePublic<H, P, S>): () => void;
    }

    Type Parameters

    • H = unknown
    • P = unknown
    • S = unknown

    Hierarchy (View Summary)

    Index

    Properties

    Methods

    Properties

    hooks?: HookEngine<any, [string]>

    The underlying cookie jar. Users may call jar.set, jar.get, etc. directly.

    name: string

    Methods

    • Force any pending coalesced persistence to commit and perform one final save. Call this on graceful shutdown (process exit, logout, etc.).

      Resolves after the save completes; rejects if the adapter throws. A no-op when no adapter is configured.

      Returns Promise<void>