mdka 1.5.0-rc.5 → 1.5.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/README.md +15 -15
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -26,42 +26,42 @@ $ npm install mdka
|
|
|
26
26
|
### Convert from HTML text
|
|
27
27
|
|
|
28
28
|
```js
|
|
29
|
-
const {
|
|
29
|
+
const { fromHtml } = require("mdka")
|
|
30
30
|
|
|
31
|
-
console.log(
|
|
32
|
-
|
|
33
|
-
|
|
31
|
+
console.log(fromHtml("<p>Hello, world.</p>"))
|
|
32
|
+
// Hello, world.
|
|
33
|
+
//
|
|
34
34
|
```
|
|
35
35
|
|
|
36
36
|
### Convert from HTML file
|
|
37
37
|
|
|
38
38
|
```js
|
|
39
|
-
const {
|
|
39
|
+
const { fromFile } = require("mdka")
|
|
40
40
|
|
|
41
|
-
console.log(
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
console.log(fromFile("tests/fixtures/simple-01.html"))
|
|
42
|
+
// Hello, world.
|
|
43
|
+
//
|
|
44
44
|
```
|
|
45
45
|
|
|
46
46
|
### Convert from HTML text and write the result to file
|
|
47
47
|
|
|
48
48
|
```js
|
|
49
|
-
const {
|
|
49
|
+
const { fromHtmlToFile } = require("mdka")
|
|
50
50
|
|
|
51
|
-
|
|
51
|
+
fromHtmlToFile("<p>Hello, world.</p>", "tests/tmp/out.md", false)
|
|
52
52
|
```
|
|
53
53
|
|
|
54
54
|
### Convert from HTML file and write the result to file
|
|
55
55
|
|
|
56
56
|
```js
|
|
57
|
-
const {
|
|
57
|
+
const { fromFileToFile } = require("mdka")
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
fromFileToFile("tests/fixtures/simple-01.html", "tests/tmp/out.md", false)
|
|
60
60
|
```
|
|
61
61
|
|
|
62
62
|
---
|
|
63
63
|
|
|
64
|
-
##
|
|
64
|
+
## Open-source, with care
|
|
65
65
|
|
|
66
66
|
This project is lovingly built and maintained by volunteers.
|
|
67
67
|
We hope it helps streamline your API development.
|
|
@@ -69,5 +69,5 @@ Please understand that the project has its own direction — while we welcome fe
|
|
|
69
69
|
|
|
70
70
|
## Acknowledgements
|
|
71
71
|
|
|
72
|
-
Depends on
|
|
73
|
-
Also, on
|
|
72
|
+
Depends on Servo's [html5ever](https://github.com/servo/html5ever) / markup5ever.
|
|
73
|
+
Also, on PyO3's [pyo3](https://github.com/PyO3/pyo3) / [maturin](https://github.com/PyO3/maturin) on bindings for Python. [napi-rs](https://github.com/napi-rs/napi-rs) for binding for Node.js.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mdka",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.2",
|
|
4
4
|
"description": "HTML to Markdown converter",
|
|
5
5
|
"author": "nabbisen<nabbisen@scqr.net>",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -67,8 +67,8 @@
|
|
|
67
67
|
"prepublishOnly": "napi prepublish --skip-gh-release"
|
|
68
68
|
},
|
|
69
69
|
"optionalDependencies": {
|
|
70
|
-
"@mdka/lib-linux-x64-gnu": "1.5.
|
|
71
|
-
"@mdka/lib-darwin-arm64": "1.5.
|
|
72
|
-
"@mdka/lib-win32-x64-msvc": "1.5.
|
|
70
|
+
"@mdka/lib-linux-x64-gnu": "1.5.2",
|
|
71
|
+
"@mdka/lib-darwin-arm64": "1.5.2",
|
|
72
|
+
"@mdka/lib-win32-x64-msvc": "1.5.2"
|
|
73
73
|
}
|
|
74
74
|
}
|