This commit is contained in:
19
docs/snippets/swift/config/html_output.md
Normal file
19
docs/snippets/swift/config/html_output.md
Normal file
@@ -0,0 +1,19 @@
|
||||
```swift title="Swift"
|
||||
import Foundation
|
||||
import Kreuzberg
|
||||
import RustBridge
|
||||
|
||||
let configJson = """
|
||||
{
|
||||
"output_format": "html",
|
||||
"html_output": {
|
||||
"theme": "github"
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
let config = try extractionConfigFromJson(configJson)
|
||||
let result = try extractFileSync("document.pdf", nil, config)
|
||||
|
||||
print(result.content().toString()) // HTML with kb-* classes
|
||||
```
|
||||
Reference in New Issue
Block a user