pdf-lib
Version:
Library for creating and modifying PDF files in JavaScript
22 lines (21 loc) • 773 B
TypeScript
import PDFDocument from '../pdf-document/PDFDocument';
declare class PDFDocumentFactory {
/**
* Creates a new [[PDFDocument]] object. Useful for creating new PDF documents.
*
* @returns The new [[PDFDocument]] object.
*/
static create: () => PDFDocument;
/**
* Loads an existing PDF document contained from the specified `Uint8Array`
* into a [[PDFDocument]] object. Useful for modifying existing PDF documents.
*
* @param data A `Uint8Array` containing the raw bytes of a PDF document.
*
* @returns A [[PDFDocument]] object initialized from the provided document.
*/
static load: (data: Uint8Array) => PDFDocument;
/** @hidden */
private static normalize;
}
export default PDFDocumentFactory;