Skip to main content

Function: renderDocumentJson()

function renderDocumentJson(json): Promise<Uint8Array<ArrayBufferLike>>;

Renders a PdfDocumentJson to PDF bytes. Asynchronous because fonts and images may be loaded from the filesystem, a URL, or Google Fonts.

Parameters

ParameterTypeDescription
jsonPdfDocumentJsonThe declarative document description.

Returns

Promise<Uint8Array<ArrayBufferLike>>

The serialized PDF as a Uint8Array.