mirror of
https://github.com/run-llama/pdf-viewer.git
synced 2026-07-01 21:34:02 -04:00
feat: add readme
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
React PDF viewer for LLM applications
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
npm install pdf-viewer
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
```jsx
|
||||
import React from 'react';
|
||||
|
||||
import { PDFViewer, PdfFocusProvider } from 'pdf-viewer';
|
||||
|
||||
const file = {
|
||||
id: 'sample-document',
|
||||
url: 'https://d687lz8k56fia.cloudfront.net/sec-edgar-filings/0001045810/10-Q/0001045810-22-000147/filing-details.pdf',
|
||||
};
|
||||
|
||||
function App() {
|
||||
return (
|
||||
<div className="AppContainer">
|
||||
<PdfFocusProvider>
|
||||
<PDFViewer file={file} />
|
||||
</PdfFocusProvider>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
```
|
||||
Reference in New Issue
Block a user