react-pdf-ner-annotator
Version:
A React component to annotate named entities directly onto a PDF.
15 lines (14 loc) • 392 B
TypeScript
import { PDFPageProxy } from 'pdfjs-dist';
interface Props {
url?: string;
data?: Uint8Array | BufferSource | string;
httpHeaders?: {
[key: string]: string;
};
}
declare const usePDF: ({ url, data, httpHeaders }: Props) => {
pages: number;
error: boolean;
fetchPage: (index: number) => Promise<PDFPageProxy> | null;
};
export default usePDF;