@kreuzberg/html-to-markdown-wasm 2.25.1 → 2.26.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/README.md +38 -162
- package/dist/html_to_markdown_wasm_bg.js +63 -63
- package/dist/html_to_markdown_wasm_bg.wasm +0 -0
- package/dist/package.json +1 -1
- package/dist-node/README.md +38 -162
- package/dist-node/html_to_markdown_wasm.js +64 -64
- package/dist-node/html_to_markdown_wasm_bg.wasm +0 -0
- package/dist-node/package.json +1 -1
- package/dist-web/README.md +38 -162
- package/dist-web/html_to_markdown_wasm.js +63 -63
- package/dist-web/html_to_markdown_wasm_bg.wasm +0 -0
- package/dist-web/package.json +1 -1
- package/package.json +1 -1
package/dist-node/README.md
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
<img src="https://img.shields.io/maven-central/v/dev.kreuzberg/html-to-markdown?label=Java&color=007ec6" alt="Java">
|
|
19
19
|
</a>
|
|
20
20
|
<a href="https://pkg.go.dev/github.com/kreuzberg-dev/html-to-markdown/packages/go/v2/htmltomarkdown">
|
|
21
|
-
<img src="https://img.shields.io/badge/Go-v2.
|
|
21
|
+
<img src="https://img.shields.io/badge/Go-v2.26.0-007ec6" alt="Go">
|
|
22
22
|
</a>
|
|
23
23
|
<a href="https://www.nuget.org/packages/KreuzbergDev.HtmlToMarkdown/">
|
|
24
24
|
<img src="https://img.shields.io/nuget/v/KreuzbergDev.HtmlToMarkdown?label=C%23&color=007ec6" alt="C#">
|
|
@@ -32,16 +32,21 @@
|
|
|
32
32
|
<a href="https://hex.pm/packages/html_to_markdown">
|
|
33
33
|
<img src="https://img.shields.io/hexpm/v/html_to_markdown?label=Elixir&color=007ec6" alt="Elixir">
|
|
34
34
|
</a>
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
<a href="https://kreuzberg-dev.r-universe.dev/htmltomarkdown">
|
|
36
|
+
<img src="https://img.shields.io/badge/R-htmltomarkdown-007ec6" alt="R">
|
|
37
|
+
</a>
|
|
38
|
+
<a href="https://github.com/kreuzberg-dev/html-to-markdown/releases">
|
|
39
|
+
<img src="https://img.shields.io/badge/C-FFI-007ec6" alt="C">
|
|
40
|
+
</a>
|
|
41
|
+
<a href="https://docs.html-to-markdown.kreuzberg.dev">
|
|
42
|
+
<img src="https://img.shields.io/badge/Docs-kreuzberg.dev-007ec6" alt="Documentation">
|
|
43
|
+
</a>
|
|
37
44
|
<a href="https://github.com/kreuzberg-dev/html-to-markdown/blob/main/LICENSE">
|
|
38
45
|
<img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License">
|
|
39
46
|
</a>
|
|
40
47
|
</div>
|
|
41
48
|
|
|
42
|
-
|
|
43
|
-
<img width="3384" height="573" alt="Linkedin- Banner" src="https://github.com/user-attachments/assets/478a83da-237b-446b-b3a8-e564c13e00a8" />
|
|
44
|
-
|
|
49
|
+
<img width="3384" height="573" alt="Banner" src="https://github.com/user-attachments/assets/478a83da-237b-446b-b3a8-e564c13e00a8" />
|
|
45
50
|
|
|
46
51
|
<div align="center" style="margin-top: 20px;">
|
|
47
52
|
<a href="https://discord.gg/pXxagNK2zN">
|
|
@@ -49,178 +54,49 @@
|
|
|
49
54
|
</a>
|
|
50
55
|
</div>
|
|
51
56
|
|
|
52
|
-
High-performance HTML
|
|
53
|
-
|
|
54
|
-
## Key Features
|
|
55
|
-
|
|
56
|
-
- **Blazing Fast** – Rust-powered core delivers 10-80× faster conversion than pure Python alternatives (150–280 MB/s)
|
|
57
|
-
- **Polyglot** – Native bindings for Rust, Python, TypeScript/Node.js, Ruby, PHP, Go, Java, C#, and Elixir
|
|
58
|
-
- **Smart Conversion** – Handles complex documents including nested tables, code blocks, task lists, and hOCR OCR output
|
|
59
|
-
- **Metadata Extraction** – Extract document metadata (title, description, headers, links, images, structured data) alongside conversion
|
|
60
|
-
- **Visitor Pattern** – Custom callbacks for domain-specific dialects, content filtering, URL rewriting, accessibility validation
|
|
61
|
-
- **Highly Configurable** – Control heading styles, code block fences, list formatting, whitespace handling, and HTML sanitization
|
|
62
|
-
- **Tag Preservation** – Keep specific HTML tags unconverted when markdown isn't expressive enough
|
|
63
|
-
- **Secure by Default** – Built-in HTML sanitization prevents malicious content
|
|
64
|
-
- **Consistent Output** – Identical markdown rendering across all language bindings
|
|
65
|
-
|
|
66
|
-
**[Try the Live Demo →](https://kreuzberg-dev.github.io/html-to-markdown/)**
|
|
67
|
-
|
|
68
|
-
## Installation
|
|
69
|
-
|
|
70
|
-
Each language binding provides comprehensive documentation with installation instructions, examples, and best practices. Choose your platform to get started:
|
|
71
|
-
|
|
72
|
-
**Scripting Languages:**
|
|
73
|
-
- **[Python](./packages/python/README.md)** – PyPI package, metadata extraction, visitor pattern, CLI included
|
|
74
|
-
- **[Ruby](./packages/ruby/README.md)** – RubyGems package, RBS type definitions, Steep checking
|
|
75
|
-
- **[PHP](./packages/php/README.md)** – Composer package + PIE extension, PHP 8.4+, PHPStan level 9
|
|
76
|
-
- **[Elixir](./packages/elixir/README.md)** – Hex package, Rustler NIF bindings, Elixir 1.19+
|
|
77
|
-
|
|
78
|
-
**JavaScript/TypeScript:**
|
|
79
|
-
- **[Node.js / TypeScript](./packages/typescript/README.md)** – Native NAPI-RS bindings for Node.js/Bun, fastest performance, WebAssembly for browsers/Deno
|
|
80
|
-
|
|
81
|
-
**Compiled Languages:**
|
|
82
|
-
- **[Go](./packages/go/v2/README.md)** – Go module with FFI bindings, automatic library download
|
|
83
|
-
- **[Java](./packages/java/README.md)** – Maven Central, Panama Foreign Function & Memory API, Java 24+
|
|
84
|
-
- **[C#](./packages/csharp/README.md)** – NuGet package, .NET 8.0+, P/Invoke FFI bindings
|
|
85
|
-
|
|
86
|
-
**Native:**
|
|
87
|
-
- **[Rust](./crates/html-to-markdown/README.md)** – Core library, flexible feature flags, zero-copy APIs
|
|
88
|
-
|
|
89
|
-
**Command-Line:**
|
|
90
|
-
- **[CLI](https://crates.io/crates/html-to-markdown-cli)** – Cross-platform binary via `cargo install html-to-markdown-cli` or Homebrew: `brew install kreuzberg-dev/tap/html-to-markdown`
|
|
91
|
-
|
|
92
|
-
<details>
|
|
93
|
-
<summary><strong>Metadata Extraction</strong></summary>
|
|
94
|
-
|
|
95
|
-
Extract comprehensive metadata during conversion: title, description, headers, links, images, structured data (JSON-LD, Microdata, RDFa). Use cases: SEO extraction, table-of-contents generation, link validation, accessibility auditing, content migration.
|
|
96
|
-
|
|
97
|
-
**[Metadata Extraction Guide →](./examples/metadata-extraction/)**
|
|
98
|
-
|
|
99
|
-
</details>
|
|
100
|
-
|
|
101
|
-
<details>
|
|
102
|
-
<summary><strong>Visitor Pattern</strong></summary>
|
|
103
|
-
|
|
104
|
-
Customize HTML→Markdown conversion with callbacks for specific elements. Intercept links, images, headings, lists, and more. Use cases: domain-specific Markdown dialects (Obsidian, Notion), content filtering, URL rewriting, accessibility validation, analytics.
|
|
105
|
-
|
|
106
|
-
Supported in: Rust, Python (sync & async), TypeScript/Node.js (sync & async), Ruby, and PHP.
|
|
107
|
-
|
|
108
|
-
**[Visitor Pattern Guide →](./examples/visitor-pattern/)**
|
|
109
|
-
|
|
110
|
-
### Visitor Support Matrix
|
|
57
|
+
High-performance HTML to Markdown conversion powered by Rust. Ships as native bindings for **Rust, Python, TypeScript/Node.js, Ruby, PHP, Go, Java, C#, Elixir, R, C (FFI), and WebAssembly** with identical rendering across all runtimes.
|
|
111
58
|
|
|
112
|
-
|
|
113
|
-
|---------|-----------------|---------------|----------|
|
|
114
|
-
| **Rust** | ✅ Yes | ✅ Tokio | Core library, performance-critical code |
|
|
115
|
-
| **Python** | ✅ Yes | ✅ asyncio | Server-side, bulk processing |
|
|
116
|
-
| **TypeScript/Node.js** | ✅ Yes | ✅ Promise-based | Server-side Node.js/Bun, best performance |
|
|
117
|
-
| **Ruby** | ✅ Yes | ❌ No | Server-side Ruby on Rails, Sinatra |
|
|
118
|
-
| **PHP** | ✅ Yes | ❌ No | Server-side PHP, content management |
|
|
119
|
-
| **Go** | ❌ No | — | Basic conversion only |
|
|
120
|
-
| **Java** | ❌ No | — | Basic conversion only |
|
|
121
|
-
| **C#** | ❌ No | — | Basic conversion only |
|
|
122
|
-
| **Elixir** | ❌ No | — | Basic conversion only |
|
|
123
|
-
| **WebAssembly** | ❌ No | — | Browser, Edge, Deno (FFI limitations) |
|
|
59
|
+
**[Documentation](https://docs.html-to-markdown.kreuzberg.dev)** | **[Live Demo](https://kreuzberg-dev.github.io/html-to-markdown/)** | **[API Reference](https://docs.html-to-markdown.kreuzberg.dev/reference/api-rust/)**
|
|
124
60
|
|
|
125
|
-
|
|
61
|
+
## Highlights
|
|
126
62
|
|
|
127
|
-
|
|
63
|
+
- **150-280 MB/s** throughput (10-80x faster than pure Python alternatives)
|
|
64
|
+
- **12 language bindings** with consistent output across all runtimes
|
|
65
|
+
- **Metadata extraction** — title, headers, links, images, structured data (JSON-LD, Microdata, RDFa)
|
|
66
|
+
- **Visitor pattern** — custom callbacks for content filtering, URL rewriting, domain-specific dialects
|
|
67
|
+
- **Secure by default** — built-in HTML sanitization via ammonia
|
|
128
68
|
|
|
129
|
-
|
|
130
|
-
<summary><strong>Performance & Benchmarking</strong></summary>
|
|
69
|
+
## Quick Start
|
|
131
70
|
|
|
132
|
-
|
|
71
|
+
```bash
|
|
72
|
+
# Rust
|
|
73
|
+
cargo add html-to-markdown-rs
|
|
133
74
|
|
|
134
|
-
|
|
75
|
+
# Python
|
|
76
|
+
pip install html-to-markdown
|
|
135
77
|
|
|
136
|
-
|
|
78
|
+
# TypeScript / Node.js
|
|
79
|
+
npm install @kreuzberg/html-to-markdown-node
|
|
137
80
|
|
|
138
|
-
|
|
139
|
-
|
|
81
|
+
# Ruby
|
|
82
|
+
gem install html-to-markdown
|
|
140
83
|
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
</details>
|
|
146
|
-
|
|
147
|
-
<details>
|
|
148
|
-
<summary><strong>Skipping Images</strong></summary>
|
|
149
|
-
|
|
150
|
-
Skip all images during conversion using the `skip_images` option. Useful for text-only extraction or when you want to filter out visual content.
|
|
151
|
-
|
|
152
|
-
**Rust:**
|
|
153
|
-
```rust
|
|
154
|
-
use html_to_markdown_rs::{convert, ConversionOptions};
|
|
155
|
-
|
|
156
|
-
let options = ConversionOptions {
|
|
157
|
-
skip_images: true,
|
|
158
|
-
..Default::default()
|
|
159
|
-
};
|
|
160
|
-
|
|
161
|
-
let html = r#"<p>Text with <img src="image.jpg" alt="pic"> image</p>"#;
|
|
162
|
-
let markdown = convert(html, Some(options))?;
|
|
163
|
-
// Output: "Text with image" (image tags are removed)
|
|
164
|
-
```
|
|
165
|
-
|
|
166
|
-
**Python:**
|
|
167
|
-
```python
|
|
168
|
-
from html_to_markdown import convert, ConversionOptions
|
|
169
|
-
|
|
170
|
-
options = ConversionOptions(skip_images=True)
|
|
171
|
-
markdown = convert(html, options)
|
|
172
|
-
```
|
|
173
|
-
|
|
174
|
-
**TypeScript/Node.js:**
|
|
175
|
-
```typescript
|
|
176
|
-
import { convert, ConversionOptions } from '@kreuzberg/html-to-markdown-node';
|
|
177
|
-
|
|
178
|
-
const options: ConversionOptions = {
|
|
179
|
-
skipImages: true,
|
|
180
|
-
};
|
|
181
|
-
|
|
182
|
-
const markdown = convert(html, options);
|
|
183
|
-
```
|
|
184
|
-
|
|
185
|
-
**Ruby:**
|
|
186
|
-
```ruby
|
|
187
|
-
require 'html_to_markdown'
|
|
188
|
-
|
|
189
|
-
options = HtmlToMarkdown::ConversionOptions.new(skip_images: true)
|
|
190
|
-
markdown = HtmlToMarkdown.convert(html, options)
|
|
191
|
-
```
|
|
192
|
-
|
|
193
|
-
**PHP:**
|
|
194
|
-
```php
|
|
195
|
-
use Goldziher\HtmlToMarkdown\HtmlToMarkdown;
|
|
196
|
-
use Goldziher\HtmlToMarkdown\Options;
|
|
197
|
-
|
|
198
|
-
$options = new Options(['skip_images' => true]);
|
|
199
|
-
$markdown = HtmlToMarkdown::convert($html, $options);
|
|
84
|
+
# CLI
|
|
85
|
+
cargo install html-to-markdown-cli
|
|
86
|
+
# or
|
|
87
|
+
brew install kreuzberg-dev/tap/html-to-markdown
|
|
200
88
|
```
|
|
201
89
|
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
</details>
|
|
90
|
+
See the **[Installation Guide](https://docs.html-to-markdown.kreuzberg.dev/getting-started/installation/)** for all languages including PHP, Go, Java, C#, Elixir, R, and WASM.
|
|
205
91
|
|
|
206
|
-
|
|
207
|
-
<summary><strong>Secure by Default</strong></summary>
|
|
92
|
+
## Part of the Kreuzberg Ecosystem
|
|
208
93
|
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
</details>
|
|
94
|
+
html-to-markdown is developed by [kreuzberg.dev](https://kreuzberg.dev) and powers the HTML conversion pipeline in [Kreuzberg](https://docs.kreuzberg.dev), a document intelligence library for extracting text from PDFs, images, and office documents.
|
|
212
95
|
|
|
213
96
|
## Contributing
|
|
214
97
|
|
|
215
|
-
Contributions
|
|
216
|
-
|
|
217
|
-
- Setting up the development environment
|
|
218
|
-
- Running tests locally (Rust 95%+ coverage, language bindings 80%+)
|
|
219
|
-
- Submitting pull requests
|
|
220
|
-
- Reporting issues
|
|
221
|
-
|
|
222
|
-
All contributions must follow code quality standards enforced via pre-commit hooks (prek).
|
|
98
|
+
Contributions welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for setup instructions and guidelines.
|
|
223
99
|
|
|
224
100
|
## License
|
|
225
101
|
|
|
226
|
-
MIT License
|
|
102
|
+
MIT License — see [LICENSE](LICENSE) for details.
|
|
@@ -790,83 +790,83 @@ exports.init = init;
|
|
|
790
790
|
function __wbg_get_imports() {
|
|
791
791
|
const import0 = {
|
|
792
792
|
__proto__: null,
|
|
793
|
-
|
|
793
|
+
__wbg_Error_83742b46f01ce22d: function(arg0, arg1) {
|
|
794
794
|
const ret = Error(getStringFromWasm0(arg0, arg1));
|
|
795
795
|
return addHeapObject(ret);
|
|
796
796
|
},
|
|
797
|
-
|
|
797
|
+
__wbg_Number_a5a435bd7bbec835: function(arg0) {
|
|
798
798
|
const ret = Number(getObject(arg0));
|
|
799
799
|
return ret;
|
|
800
800
|
},
|
|
801
|
-
|
|
801
|
+
__wbg_String_8564e559799eccda: function(arg0, arg1) {
|
|
802
802
|
const ret = String(getObject(arg1));
|
|
803
803
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
804
804
|
const len1 = WASM_VECTOR_LEN;
|
|
805
805
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
806
806
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
807
807
|
},
|
|
808
|
-
|
|
808
|
+
__wbg___wbindgen_bigint_get_as_i64_447a76b5c6ef7bda: function(arg0, arg1) {
|
|
809
809
|
const v = getObject(arg1);
|
|
810
810
|
const ret = typeof(v) === 'bigint' ? v : undefined;
|
|
811
811
|
getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
|
|
812
812
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
813
813
|
},
|
|
814
|
-
|
|
814
|
+
__wbg___wbindgen_boolean_get_c0f3f60bac5a78d1: function(arg0) {
|
|
815
815
|
const v = getObject(arg0);
|
|
816
816
|
const ret = typeof(v) === 'boolean' ? v : undefined;
|
|
817
817
|
return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
|
|
818
818
|
},
|
|
819
|
-
|
|
819
|
+
__wbg___wbindgen_debug_string_5398f5bb970e0daa: function(arg0, arg1) {
|
|
820
820
|
const ret = debugString(getObject(arg1));
|
|
821
821
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
822
822
|
const len1 = WASM_VECTOR_LEN;
|
|
823
823
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
824
824
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
825
825
|
},
|
|
826
|
-
|
|
826
|
+
__wbg___wbindgen_in_41dbb8413020e076: function(arg0, arg1) {
|
|
827
827
|
const ret = getObject(arg0) in getObject(arg1);
|
|
828
828
|
return ret;
|
|
829
829
|
},
|
|
830
|
-
|
|
830
|
+
__wbg___wbindgen_is_bigint_e2141d4f045b7eda: function(arg0) {
|
|
831
831
|
const ret = typeof(getObject(arg0)) === 'bigint';
|
|
832
832
|
return ret;
|
|
833
833
|
},
|
|
834
|
-
|
|
834
|
+
__wbg___wbindgen_is_function_3c846841762788c1: function(arg0) {
|
|
835
835
|
const ret = typeof(getObject(arg0)) === 'function';
|
|
836
836
|
return ret;
|
|
837
837
|
},
|
|
838
|
-
|
|
838
|
+
__wbg___wbindgen_is_null_0b605fc6b167c56f: function(arg0) {
|
|
839
839
|
const ret = getObject(arg0) === null;
|
|
840
840
|
return ret;
|
|
841
841
|
},
|
|
842
|
-
|
|
842
|
+
__wbg___wbindgen_is_object_781bc9f159099513: function(arg0) {
|
|
843
843
|
const val = getObject(arg0);
|
|
844
844
|
const ret = typeof(val) === 'object' && val !== null;
|
|
845
845
|
return ret;
|
|
846
846
|
},
|
|
847
|
-
|
|
847
|
+
__wbg___wbindgen_is_string_7ef6b97b02428fae: function(arg0) {
|
|
848
848
|
const ret = typeof(getObject(arg0)) === 'string';
|
|
849
849
|
return ret;
|
|
850
850
|
},
|
|
851
|
-
|
|
851
|
+
__wbg___wbindgen_is_undefined_52709e72fb9f179c: function(arg0) {
|
|
852
852
|
const ret = getObject(arg0) === undefined;
|
|
853
853
|
return ret;
|
|
854
854
|
},
|
|
855
|
-
|
|
855
|
+
__wbg___wbindgen_jsval_eq_ee31bfad3e536463: function(arg0, arg1) {
|
|
856
856
|
const ret = getObject(arg0) === getObject(arg1);
|
|
857
857
|
return ret;
|
|
858
858
|
},
|
|
859
|
-
|
|
859
|
+
__wbg___wbindgen_jsval_loose_eq_5bcc3bed3c69e72b: function(arg0, arg1) {
|
|
860
860
|
const ret = getObject(arg0) == getObject(arg1);
|
|
861
861
|
return ret;
|
|
862
862
|
},
|
|
863
|
-
|
|
863
|
+
__wbg___wbindgen_number_get_34bb9d9dcfa21373: function(arg0, arg1) {
|
|
864
864
|
const obj = getObject(arg1);
|
|
865
865
|
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
866
866
|
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
867
867
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
868
868
|
},
|
|
869
|
-
|
|
869
|
+
__wbg___wbindgen_string_get_395e606bd0ee4427: function(arg0, arg1) {
|
|
870
870
|
const obj = getObject(arg1);
|
|
871
871
|
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
872
872
|
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
@@ -874,22 +874,22 @@ function __wbg_get_imports() {
|
|
|
874
874
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
875
875
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
876
876
|
},
|
|
877
|
-
|
|
877
|
+
__wbg___wbindgen_throw_6ddd609b62940d55: function(arg0, arg1) {
|
|
878
878
|
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
879
879
|
},
|
|
880
|
-
|
|
880
|
+
__wbg_call_e133b57c9155d22c: function() { return handleError(function (arg0, arg1) {
|
|
881
881
|
const ret = getObject(arg0).call(getObject(arg1));
|
|
882
882
|
return addHeapObject(ret);
|
|
883
883
|
}, arguments); },
|
|
884
|
-
|
|
884
|
+
__wbg_codePointAt_3925396be3b2c733: function(arg0, arg1) {
|
|
885
885
|
const ret = getObject(arg0).codePointAt(arg1 >>> 0);
|
|
886
886
|
return addHeapObject(ret);
|
|
887
887
|
},
|
|
888
|
-
|
|
888
|
+
__wbg_done_08ce71ee07e3bd17: function(arg0) {
|
|
889
889
|
const ret = getObject(arg0).done;
|
|
890
890
|
return ret;
|
|
891
891
|
},
|
|
892
|
-
|
|
892
|
+
__wbg_error_a6fa202b58aa1cd3: function(arg0, arg1) {
|
|
893
893
|
let deferred0_0;
|
|
894
894
|
let deferred0_1;
|
|
895
895
|
try {
|
|
@@ -900,19 +900,19 @@ function __wbg_get_imports() {
|
|
|
900
900
|
wasm.__wbindgen_export4(deferred0_0, deferred0_1, 1);
|
|
901
901
|
}
|
|
902
902
|
},
|
|
903
|
-
|
|
904
|
-
const ret = getObject(arg0)[arg1 >>> 0];
|
|
905
|
-
return addHeapObject(ret);
|
|
906
|
-
},
|
|
907
|
-
__wbg_get_b3ed3ad4be2bc8ac: function() { return handleError(function (arg0, arg1) {
|
|
903
|
+
__wbg_get_326e41e095fb2575: function() { return handleError(function (arg0, arg1) {
|
|
908
904
|
const ret = Reflect.get(getObject(arg0), getObject(arg1));
|
|
909
905
|
return addHeapObject(ret);
|
|
910
906
|
}, arguments); },
|
|
911
|
-
|
|
907
|
+
__wbg_get_unchecked_329cfe50afab7352: function(arg0, arg1) {
|
|
908
|
+
const ret = getObject(arg0)[arg1 >>> 0];
|
|
909
|
+
return addHeapObject(ret);
|
|
910
|
+
},
|
|
911
|
+
__wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
|
|
912
912
|
const ret = getObject(arg0)[getObject(arg1)];
|
|
913
913
|
return addHeapObject(ret);
|
|
914
914
|
},
|
|
915
|
-
|
|
915
|
+
__wbg_instanceof_ArrayBuffer_101e2bf31071a9f6: function(arg0) {
|
|
916
916
|
let result;
|
|
917
917
|
try {
|
|
918
918
|
result = getObject(arg0) instanceof ArrayBuffer;
|
|
@@ -922,7 +922,7 @@ function __wbg_get_imports() {
|
|
|
922
922
|
const ret = result;
|
|
923
923
|
return ret;
|
|
924
924
|
},
|
|
925
|
-
|
|
925
|
+
__wbg_instanceof_Object_be1962063fcc0c9f: function(arg0) {
|
|
926
926
|
let result;
|
|
927
927
|
try {
|
|
928
928
|
result = getObject(arg0) instanceof Object;
|
|
@@ -932,7 +932,7 @@ function __wbg_get_imports() {
|
|
|
932
932
|
const ret = result;
|
|
933
933
|
return ret;
|
|
934
934
|
},
|
|
935
|
-
|
|
935
|
+
__wbg_instanceof_Uint8Array_740438561a5b956d: function(arg0) {
|
|
936
936
|
let result;
|
|
937
937
|
try {
|
|
938
938
|
result = getObject(arg0) instanceof Uint8Array;
|
|
@@ -942,91 +942,91 @@ function __wbg_get_imports() {
|
|
|
942
942
|
const ret = result;
|
|
943
943
|
return ret;
|
|
944
944
|
},
|
|
945
|
-
|
|
945
|
+
__wbg_isArray_33b91feb269ff46e: function(arg0) {
|
|
946
946
|
const ret = Array.isArray(getObject(arg0));
|
|
947
947
|
return ret;
|
|
948
948
|
},
|
|
949
|
-
|
|
949
|
+
__wbg_isSafeInteger_ecd6a7f9c3e053cd: function(arg0) {
|
|
950
950
|
const ret = Number.isSafeInteger(getObject(arg0));
|
|
951
951
|
return ret;
|
|
952
952
|
},
|
|
953
|
-
|
|
953
|
+
__wbg_iterator_d8f549ec8fb061b1: function() {
|
|
954
954
|
const ret = Symbol.iterator;
|
|
955
955
|
return addHeapObject(ret);
|
|
956
956
|
},
|
|
957
|
-
|
|
957
|
+
__wbg_keys_ab0d051a1c55236d: function(arg0) {
|
|
958
958
|
const ret = Object.keys(getObject(arg0));
|
|
959
959
|
return addHeapObject(ret);
|
|
960
960
|
},
|
|
961
|
-
|
|
961
|
+
__wbg_length_15d3fc853a68bbbc: function(arg0) {
|
|
962
962
|
const ret = getObject(arg0).length;
|
|
963
963
|
return ret;
|
|
964
964
|
},
|
|
965
|
-
|
|
965
|
+
__wbg_length_b3416cf66a5452c8: function(arg0) {
|
|
966
966
|
const ret = getObject(arg0).length;
|
|
967
967
|
return ret;
|
|
968
968
|
},
|
|
969
|
-
|
|
969
|
+
__wbg_length_ea16607d7b61445b: function(arg0) {
|
|
970
970
|
const ret = getObject(arg0).length;
|
|
971
971
|
return ret;
|
|
972
972
|
},
|
|
973
|
-
|
|
974
|
-
const ret = new
|
|
973
|
+
__wbg_new_227d7c05414eb861: function() {
|
|
974
|
+
const ret = new Error();
|
|
975
975
|
return addHeapObject(ret);
|
|
976
976
|
},
|
|
977
|
-
|
|
978
|
-
const ret = new
|
|
977
|
+
__wbg_new_49d5571bd3f0c4d4: function() {
|
|
978
|
+
const ret = new Map();
|
|
979
979
|
return addHeapObject(ret);
|
|
980
980
|
},
|
|
981
|
-
|
|
982
|
-
const ret = new
|
|
981
|
+
__wbg_new_5f486cdf45a04d78: function(arg0) {
|
|
982
|
+
const ret = new Uint8Array(getObject(arg0));
|
|
983
983
|
return addHeapObject(ret);
|
|
984
984
|
},
|
|
985
|
-
|
|
986
|
-
const ret = new
|
|
985
|
+
__wbg_new_a70fbab9066b301f: function() {
|
|
986
|
+
const ret = new Array();
|
|
987
987
|
return addHeapObject(ret);
|
|
988
988
|
},
|
|
989
|
-
|
|
990
|
-
const ret = new
|
|
989
|
+
__wbg_new_ab79df5bd7c26067: function() {
|
|
990
|
+
const ret = new Object();
|
|
991
991
|
return addHeapObject(ret);
|
|
992
992
|
},
|
|
993
|
-
|
|
993
|
+
__wbg_new_from_slice_22da9388ac046e50: function(arg0, arg1) {
|
|
994
994
|
const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
|
|
995
995
|
return addHeapObject(ret);
|
|
996
996
|
},
|
|
997
|
-
|
|
997
|
+
__wbg_next_11b99ee6237339e3: function() { return handleError(function (arg0) {
|
|
998
998
|
const ret = getObject(arg0).next();
|
|
999
999
|
return addHeapObject(ret);
|
|
1000
1000
|
}, arguments); },
|
|
1001
|
-
|
|
1001
|
+
__wbg_next_e01a967809d1aa68: function(arg0) {
|
|
1002
1002
|
const ret = getObject(arg0).next;
|
|
1003
1003
|
return addHeapObject(ret);
|
|
1004
1004
|
},
|
|
1005
|
-
|
|
1005
|
+
__wbg_prototypesetcall_d62e5099504357e6: function(arg0, arg1, arg2) {
|
|
1006
1006
|
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
|
|
1007
1007
|
},
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
return addHeapObject(ret);
|
|
1008
|
+
__wbg_set_282384002438957f: function(arg0, arg1, arg2) {
|
|
1009
|
+
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
|
1011
1010
|
},
|
|
1012
|
-
|
|
1011
|
+
__wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
|
|
1013
1012
|
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
1014
1013
|
},
|
|
1015
|
-
|
|
1014
|
+
__wbg_set_7eaa4f96924fd6b3: function() { return handleError(function (arg0, arg1, arg2) {
|
|
1016
1015
|
const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));
|
|
1017
1016
|
return ret;
|
|
1018
1017
|
}, arguments); },
|
|
1019
|
-
|
|
1020
|
-
getObject(arg0)
|
|
1018
|
+
__wbg_set_bf7251625df30a02: function(arg0, arg1, arg2) {
|
|
1019
|
+
const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
|
|
1020
|
+
return addHeapObject(ret);
|
|
1021
1021
|
},
|
|
1022
|
-
|
|
1022
|
+
__wbg_stack_3b0d974bbf31e44f: function(arg0, arg1) {
|
|
1023
1023
|
const ret = getObject(arg1).stack;
|
|
1024
1024
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
1025
1025
|
const len1 = WASM_VECTOR_LEN;
|
|
1026
1026
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1027
1027
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1028
1028
|
},
|
|
1029
|
-
|
|
1029
|
+
__wbg_value_21fc78aab0322612: function(arg0) {
|
|
1030
1030
|
const ret = getObject(arg0).value;
|
|
1031
1031
|
return addHeapObject(ret);
|
|
1032
1032
|
},
|
|
@@ -1167,7 +1167,7 @@ function debugString(val) {
|
|
|
1167
1167
|
}
|
|
1168
1168
|
|
|
1169
1169
|
function dropObject(idx) {
|
|
1170
|
-
if (idx <
|
|
1170
|
+
if (idx < 1028) return;
|
|
1171
1171
|
heap[idx] = heap_next;
|
|
1172
1172
|
heap_next = idx;
|
|
1173
1173
|
}
|
|
@@ -1231,7 +1231,7 @@ function handleError(f, args) {
|
|
|
1231
1231
|
}
|
|
1232
1232
|
}
|
|
1233
1233
|
|
|
1234
|
-
let heap = new Array(
|
|
1234
|
+
let heap = new Array(1024).fill(undefined);
|
|
1235
1235
|
heap.push(undefined, null, true, false);
|
|
1236
1236
|
|
|
1237
1237
|
let heap_next = heap.length;
|
|
@@ -1307,5 +1307,5 @@ let WASM_VECTOR_LEN = 0;
|
|
|
1307
1307
|
const wasmPath = `${__dirname}/html_to_markdown_wasm_bg.wasm`;
|
|
1308
1308
|
const wasmBytes = require('fs').readFileSync(wasmPath);
|
|
1309
1309
|
const wasmModule = new WebAssembly.Module(wasmBytes);
|
|
1310
|
-
|
|
1310
|
+
let wasm = new WebAssembly.Instance(wasmModule, __wbg_get_imports()).exports;
|
|
1311
1311
|
wasm.__wbindgen_start();
|
|
Binary file
|