UNPKG

react-pdf-highlighter

Version:
44 lines (27 loc) 895 B
☕️ [Buy me a coffee](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=SC4D2NS8G2JJ8&source=url) ![Node CI](https://github.com/agentcooper/react-pdf-highlighter/workflows/Node%20CI/badge.svg) # react-pdf-highlighter Set of React components for PDF annotation. Features: - Built on top of PDF.js - Text and image highlights - Popover text for highlights - Scroll to highlights ## Importing CSS The bundled CSS include the CSS for pdfjs. ```tsx import "react-pdf-highlighter/dist/style.css"; ``` ## Example See demo https://agentcooper.github.io/react-pdf-highlighter/. To run the example app locally: ```bash npm install npm start ``` ## Install ```bash npm install react-pdf-highlighter ``` ## How to use See [`./example/src/App.tsx`](https://github.com/agentcooper/react-pdf-highlighter/blob/main/example/src/App.tsx) for the React component API example.