This commit is contained in:
10
docs/snippets/wasm/getting-started/extract_file.md
Normal file
10
docs/snippets/wasm/getting-started/extract_file.md
Normal file
@@ -0,0 +1,10 @@
|
||||
```typescript title="WASM"
|
||||
import init, { extractFile } from "kreuzberg-wasm";
|
||||
|
||||
await init();
|
||||
|
||||
const result = await extractFile("document.pdf", undefined, undefined);
|
||||
console.log(`Extracted content: ${result.content}`);
|
||||
console.log(`Tables found: ${result.tables?.length ?? 0}`);
|
||||
console.log(`Format: ${result.metadata?.format ?? "unknown"}`);
|
||||
```
|
||||
Reference in New Issue
Block a user