pdfrx_web
    Preparing search index...

    Type Alias PdfSource

    PdfSource:
        | string
        | URL
        | File
        | Blob
        | Uint8Array
        | ArrayBuffer
        | { url: string
        | URL } & PdfOpenUrlOptions
        | { data: Uint8Array | ArrayBuffer | File | Blob } & PdfOpenDataOptions
        | null
        | undefined

    A document to open, in whatever shape is most convenient.

    The shorthands (string, URL, File, Blob, Uint8Array, ArrayBuffer) cover the common cases; the object forms exist when you need to pass passwordProvider, HTTP headers, or a sourceName alongside the data.

    null/undefined means "no document" — the viewer is created but stays empty, and you can open something later with usePdfrxViewer.

    <PdfrxProvider src="/manual.pdf" />
    <PdfrxProvider src={{ url: '/secret.pdf', passwordProvider: () => prompt('password') }} />
    <PdfrxProvider src={{ data: bytes, sourceName: 'upload.pdf' }} />