@qrcommunication/gigapdf-lib — SDK API reference - v0.110.3
    Preparing search index...

    Interface HtmlRenderOptions

    interface HtmlRenderOptions {
        pageSize?: string;
        pageWidth?: number;
        pageHeight?: number;
        margin?: number | HtmlMargins;
        header?: string;
        footer?: string;
        headerOffset?: number;
        footerOffset?: number;
        startPageNumber?: number;
        resources?: HtmlResource[];
    }
    Index

    Properties

    pageSize?: string

    Named paper size ("A4", "a3-landscape", "letter", …) — wins over width/height.

    pageWidth?: number

    Explicit page width in points (default 612 = US Letter). Ignored if pageSize is set.

    pageHeight?: number

    Explicit page height in points (default 792). Ignored if pageSize is set.

    margin?: number | HtmlMargins

    Uniform margin (points) or per-side margins. Default 36pt (0.5in).

    header?: string

    Running header HTML painted in the top margin ({{page}} / {{pages}} tokens).

    footer?: string

    Running footer HTML painted in the bottom margin (same tokens).

    headerOffset?: number

    Distance from the top edge to the header block, in points (default 18).

    footerOffset?: number

    Distance from the bottom edge to the footer block, in points (default 18).

    startPageNumber?: number

    Number assigned to the first page for {{page}} (default 1).

    resources?: HtmlResource[]

    Host-downloaded external images, keyed by the exact URL referenced in the HTML (<img src>). Obtain the list with GigaPdfEngine.htmlNeededResources, fetch each, and pass the bytes here — the engine never touches the network. data: URIs need no entry.