@lowlighter/xml 5.2.2 → 5.3.1

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/deno.jsonc CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "icon": "📃",
3
3
  "name": "@libs/xml",
4
- "version": "5.2.2",
4
+ "version": "5.3.1",
5
5
  "description": "XML parser/stringifier with no dependencies.",
6
6
  "keywords": [
7
7
  "xml",
@@ -25,6 +25,7 @@
25
25
  "type": "git",
26
26
  "url": "git+https://github.com/lowlighter/libs.git"
27
27
  },
28
+ "npm": true,
28
29
  "exports": {
29
30
  ".": "./mod.ts",
30
31
  "./parse": "./parse.ts",
@@ -32,8 +33,8 @@
32
33
  },
33
34
  "imports": {
34
35
  "@std/fs/expand-glob": "jsr:@std/fs@0.229.1/expand-glob",
35
- "@std/path/from-file-url": "jsr:@std/path@0.225.1/from-file-url",
36
36
  "@std/fs/exists": "jsr:@std/fs@0.229.1/exists",
37
+ "@std/path/from-file-url": "jsr:@std/path@0.225.1/from-file-url",
37
38
  "@libs/typing": "jsr:@libs/typing@2",
38
39
  "@libs/testing": "jsr:@libs/testing@1"
39
40
  },
@@ -83,6 +84,8 @@
83
84
  "coverage",
84
85
  "**/coverage",
85
86
  "**/node_modules",
87
+ "**/package.json",
88
+ "**/package-lock.json",
86
89
  "**/wasm_*",
87
90
  "**/*.mjs"
88
91
  ]
package/deno.lock CHANGED
@@ -2,35 +2,29 @@
2
2
  "version": "3",
3
3
  "packages": {
4
4
  "specifiers": {
5
- "jsr:@libs/testing@1": "jsr:@libs/testing@1.0.4",
6
- "jsr:@libs/typing@2": "jsr:@libs/typing@2.0.3",
5
+ "jsr:@libs/testing@1": "jsr:@libs/testing@1.0.7",
6
+ "jsr:@libs/typing@2": "jsr:@libs/typing@2.1.0",
7
7
  "jsr:@std/assert@^0.224.0": "jsr:@std/assert@0.224.0",
8
- "jsr:@std/assert@^0.225.2": "jsr:@std/assert@0.225.3",
9
8
  "jsr:@std/expect@0.224.0": "jsr:@std/expect@0.224.0",
10
9
  "jsr:@std/fmt@^0.224.0": "jsr:@std/fmt@0.224.0",
11
10
  "jsr:@std/fs@0.229.1": "jsr:@std/fs@0.229.1",
12
11
  "jsr:@std/internal@^0.224.0": "jsr:@std/internal@0.224.0",
13
12
  "jsr:@std/path@0.225.1": "jsr:@std/path@0.225.1",
14
- "jsr:@std/path@^0.225.1": "jsr:@std/path@0.225.1",
15
13
  "npm:@types/node": "npm:@types/node@18.16.19"
16
14
  },
17
15
  "jsr": {
18
- "@libs/testing@1.0.4": {
19
- "integrity": "9e3d28f5458a68435b49b870f8a2137ae79a09d2f10f16c4a6603d6ef7bf3873",
16
+ "@libs/testing@1.0.7": {
17
+ "integrity": "b1a7caa9d2e00569f90b9753eb768ec6b16ff5c859f104b73a6ef4611968892e",
20
18
  "dependencies": [
21
- "jsr:@std/expect@0.224.0",
22
- "jsr:@std/path@0.225.1"
19
+ "jsr:@std/expect@0.224.0"
23
20
  ]
24
21
  },
25
- "@libs/typing@2.0.3": {
26
- "integrity": "e2fb7b9f4a09ffbe322377e05a16dfd48e04249ed667e4c9c06ca166c48b379e"
22
+ "@libs/typing@2.1.0": {
23
+ "integrity": "3c3b93e1da1e4bb45a22dde168fdfd1cc765edbdb371b46bf4ca7873ee79e15d"
27
24
  },
28
25
  "@std/assert@0.224.0": {
29
26
  "integrity": "8643233ec7aec38a940a8264a6e3eed9bfa44e7a71cc6b3c8874213ff401967f"
30
27
  },
31
- "@std/assert@0.225.3": {
32
- "integrity": "b3c2847aecf6955b50644cdb9cf072004ea3d1998dd7579fc0acb99dbb23bd4f"
33
- },
34
28
  "@std/expect@0.224.0": {
35
29
  "integrity": "54bc071f7edcbd7bb4531f913e466e5ec3642f401dc3771fe5975f0693f25969",
36
30
  "dependencies": [
@@ -43,11 +37,7 @@
43
37
  "integrity": "e20e9a2312a8b5393272c26191c0a68eda8d2c4b08b046bad1673148f1d69851"
44
38
  },
45
39
  "@std/fs@0.229.1": {
46
- "integrity": "38d3fb31f0ca0a8c1118e039939188f32e291a3f7f17dc0868fec22024bdfadd",
47
- "dependencies": [
48
- "jsr:@std/assert@^0.225.2",
49
- "jsr:@std/path@^0.225.1"
50
- ]
40
+ "integrity": "38d3fb31f0ca0a8c1118e039939188f32e291a3f7f17dc0868fec22024bdfadd"
51
41
  },
52
42
  "@std/internal@0.224.0": {
53
43
  "integrity": "afc50644f9cdf4495eeb80523a8f6d27226b4b36c45c7c195dfccad4b8509291"
@@ -63,18 +53,7 @@
63
53
  }
64
54
  }
65
55
  },
66
- "remote": {
67
- "https://deno.land/x/xml@3.0.2/parse.ts": "057782a8fbee64ebcc608896010016f4579b6799cdd4fe8da9cb1a134b83e92f",
68
- "https://deno.land/x/xml@3.0.2/utils/parser.ts": "f900943e40bf79f75b7a6effb965ed10a868e3b3134dbddfbf559c7c5e8cd25e",
69
- "https://deno.land/x/xml@3.0.2/utils/stream.ts": "daa6443695261c1190da38090822d85353e20af3ebaa145e0314b0cf1d6a018e",
70
- "https://deno.land/x/xml@3.0.2/utils/streamable.ts": "1603a5f10c859b95d4e9502365a0fba0b19d5d068356e20d5a6813cd37fee780",
71
- "https://deno.land/x/xml@3.0.2/utils/types.ts": "9cd1ee34e70f8ef13815d269b5316f3a3ecc90edf09d4a50e03065986d584ad3",
72
- "https://deno.land/x/xml@4.0.0/parse.ts": "057782a8fbee64ebcc608896010016f4579b6799cdd4fe8da9cb1a134b83e92f",
73
- "https://deno.land/x/xml@4.0.0/utils/parser.ts": "1c0701421fd342da5f57dbf3d2ad82956517cb88f15027c3b6628ee1870e59b1",
74
- "https://deno.land/x/xml@4.0.0/utils/stream.ts": "4cfd7e4daf11cdae80ba636ba0d10ca79cc8812365d66cb9d7b1d777af419e19",
75
- "https://deno.land/x/xml@4.0.0/utils/streamable.ts": "1603a5f10c859b95d4e9502365a0fba0b19d5d068356e20d5a6813cd37fee780",
76
- "https://deno.land/x/xml@4.0.0/utils/types.ts": "f5dd32c96f85813a93d155bf8eb2aba88e11c7805c87e97aff12cbaa48db627b"
77
- },
56
+ "remote": {},
78
57
  "workspace": {
79
58
  "dependencies": [
80
59
  "jsr:@libs/testing@1",
package/mod.ts CHANGED
@@ -1,3 +1,3 @@
1
- export { parse } from "./parse.ts"
2
- export { stringify } from "./stringify.ts"
3
- export type { xml_document, xml_node, xml_text } from "./_types.ts"
1
+ export { type options as parse_options, parse } from "./parse.ts"
2
+ export { type options as stringify_options, stringify } from "./stringify.ts"
3
+ export type * from "./_types.ts"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lowlighter/xml",
3
- "version": "5.2.2",
3
+ "version": "5.3.1",
4
4
  "type": "module",
5
5
  "scripts": {},
6
6
  "description": "XML parser/stringifier with no dependencies.",
package/parse.ts CHANGED
@@ -443,23 +443,3 @@ function revive(node: xml_node | xml_text, key: string, options: options) {
443
443
 
444
444
  /** Synchronous reader. */
445
445
  type ReaderSync = { readSync(buffer: Uint8Array): Nullable<number> }
446
-
447
- //TODO(@lowlighter): implement async parsing
448
- /** Asynchronous reader. */
449
- //type Reader = { read(buffer: Uint8Array): Promise<Nullable<number>> }
450
-
451
- /*
452
- class MockReader implements Reader {
453
- constructor(string: string) {
454
- this.#data = new TextEncoder().encode(string)
455
- }
456
- readonly #data
457
- #cursor = 0
458
- async read(buffer: Uint8Array) {
459
- const bytes = this.#data.slice(this.#cursor, this.#cursor + buffer.length)
460
- buffer.set(bytes)
461
- this.#cursor = Math.min(this.#cursor + bytes.length, this.#data.length)
462
- return bytes.length || null
463
- }
464
- }
465
- */
@@ -1,159 +1,159 @@
1
- # This file is automatically @generated by Cargo.
2
- # It is not intended for manual editing.
3
- version = 3
4
-
5
- [[package]]
6
- name = "bumpalo"
7
- version = "3.16.0"
8
- source = "registry+https://github.com/rust-lang/crates.io-index"
9
- checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c"
10
-
11
- [[package]]
12
- name = "cfg-if"
13
- version = "1.0.0"
14
- source = "registry+https://github.com/rust-lang/crates.io-index"
15
- checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
16
-
17
- [[package]]
18
- name = "js-sys"
19
- version = "0.3.69"
20
- source = "registry+https://github.com/rust-lang/crates.io-index"
21
- checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d"
22
- dependencies = [
23
- "wasm-bindgen",
24
- ]
25
-
26
- [[package]]
27
- name = "log"
28
- version = "0.4.21"
29
- source = "registry+https://github.com/rust-lang/crates.io-index"
30
- checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c"
31
-
32
- [[package]]
33
- name = "memchr"
34
- version = "2.7.2"
35
- source = "registry+https://github.com/rust-lang/crates.io-index"
36
- checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d"
37
-
38
- [[package]]
39
- name = "once_cell"
40
- version = "1.19.0"
41
- source = "registry+https://github.com/rust-lang/crates.io-index"
42
- checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92"
43
-
44
- [[package]]
45
- name = "proc-macro2"
46
- version = "1.0.82"
47
- source = "registry+https://github.com/rust-lang/crates.io-index"
48
- checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b"
49
- dependencies = [
50
- "unicode-ident",
51
- ]
52
-
53
- [[package]]
54
- name = "quick-xml"
55
- version = "0.31.0"
56
- source = "registry+https://github.com/rust-lang/crates.io-index"
57
- checksum = "1004a344b30a54e2ee58d66a71b32d2db2feb0a31f9a2d302bf0536f15de2a33"
58
- dependencies = [
59
- "memchr",
60
- ]
61
-
62
- [[package]]
63
- name = "quote"
64
- version = "1.0.36"
65
- source = "registry+https://github.com/rust-lang/crates.io-index"
66
- checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7"
67
- dependencies = [
68
- "proc-macro2",
69
- ]
70
-
71
- [[package]]
72
- name = "syn"
73
- version = "2.0.64"
74
- source = "registry+https://github.com/rust-lang/crates.io-index"
75
- checksum = "7ad3dee41f36859875573074334c200d1add8e4a87bb37113ebd31d926b7b11f"
76
- dependencies = [
77
- "proc-macro2",
78
- "quote",
79
- "unicode-ident",
80
- ]
81
-
82
- [[package]]
83
- name = "unicode-ident"
84
- version = "1.0.12"
85
- source = "registry+https://github.com/rust-lang/crates.io-index"
86
- checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b"
87
-
88
- [[package]]
89
- name = "wasm-bindgen"
90
- version = "0.2.92"
91
- source = "registry+https://github.com/rust-lang/crates.io-index"
92
- checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8"
93
- dependencies = [
94
- "cfg-if",
95
- "wasm-bindgen-macro",
96
- ]
97
-
98
- [[package]]
99
- name = "wasm-bindgen-backend"
100
- version = "0.2.92"
101
- source = "registry+https://github.com/rust-lang/crates.io-index"
102
- checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da"
103
- dependencies = [
104
- "bumpalo",
105
- "log",
106
- "once_cell",
107
- "proc-macro2",
108
- "quote",
109
- "syn",
110
- "wasm-bindgen-shared",
111
- ]
112
-
113
- [[package]]
114
- name = "wasm-bindgen-macro"
115
- version = "0.2.92"
116
- source = "registry+https://github.com/rust-lang/crates.io-index"
117
- checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726"
118
- dependencies = [
119
- "quote",
120
- "wasm-bindgen-macro-support",
121
- ]
122
-
123
- [[package]]
124
- name = "wasm-bindgen-macro-support"
125
- version = "0.2.92"
126
- source = "registry+https://github.com/rust-lang/crates.io-index"
127
- checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7"
128
- dependencies = [
129
- "proc-macro2",
130
- "quote",
131
- "syn",
132
- "wasm-bindgen-backend",
133
- "wasm-bindgen-shared",
134
- ]
135
-
136
- [[package]]
137
- name = "wasm-bindgen-shared"
138
- version = "0.2.92"
139
- source = "registry+https://github.com/rust-lang/crates.io-index"
140
- checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96"
141
-
142
- [[package]]
143
- name = "wasm_xml_parser"
144
- version = "0.1.0"
145
- dependencies = [
146
- "quick-xml",
147
- "wasm-bindgen",
148
- "web-sys",
149
- ]
150
-
151
- [[package]]
152
- name = "web-sys"
153
- version = "0.3.69"
154
- source = "registry+https://github.com/rust-lang/crates.io-index"
155
- checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef"
156
- dependencies = [
157
- "js-sys",
158
- "wasm-bindgen",
159
- ]
1
+ # This file is automatically @generated by Cargo.
2
+ # It is not intended for manual editing.
3
+ version = 3
4
+
5
+ [[package]]
6
+ name = "bumpalo"
7
+ version = "3.16.0"
8
+ source = "registry+https://github.com/rust-lang/crates.io-index"
9
+ checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c"
10
+
11
+ [[package]]
12
+ name = "cfg-if"
13
+ version = "1.0.0"
14
+ source = "registry+https://github.com/rust-lang/crates.io-index"
15
+ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
16
+
17
+ [[package]]
18
+ name = "js-sys"
19
+ version = "0.3.69"
20
+ source = "registry+https://github.com/rust-lang/crates.io-index"
21
+ checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d"
22
+ dependencies = [
23
+ "wasm-bindgen",
24
+ ]
25
+
26
+ [[package]]
27
+ name = "log"
28
+ version = "0.4.21"
29
+ source = "registry+https://github.com/rust-lang/crates.io-index"
30
+ checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c"
31
+
32
+ [[package]]
33
+ name = "memchr"
34
+ version = "2.7.2"
35
+ source = "registry+https://github.com/rust-lang/crates.io-index"
36
+ checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d"
37
+
38
+ [[package]]
39
+ name = "once_cell"
40
+ version = "1.19.0"
41
+ source = "registry+https://github.com/rust-lang/crates.io-index"
42
+ checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92"
43
+
44
+ [[package]]
45
+ name = "proc-macro2"
46
+ version = "1.0.82"
47
+ source = "registry+https://github.com/rust-lang/crates.io-index"
48
+ checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b"
49
+ dependencies = [
50
+ "unicode-ident",
51
+ ]
52
+
53
+ [[package]]
54
+ name = "quick-xml"
55
+ version = "0.31.0"
56
+ source = "registry+https://github.com/rust-lang/crates.io-index"
57
+ checksum = "1004a344b30a54e2ee58d66a71b32d2db2feb0a31f9a2d302bf0536f15de2a33"
58
+ dependencies = [
59
+ "memchr",
60
+ ]
61
+
62
+ [[package]]
63
+ name = "quote"
64
+ version = "1.0.36"
65
+ source = "registry+https://github.com/rust-lang/crates.io-index"
66
+ checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7"
67
+ dependencies = [
68
+ "proc-macro2",
69
+ ]
70
+
71
+ [[package]]
72
+ name = "syn"
73
+ version = "2.0.64"
74
+ source = "registry+https://github.com/rust-lang/crates.io-index"
75
+ checksum = "7ad3dee41f36859875573074334c200d1add8e4a87bb37113ebd31d926b7b11f"
76
+ dependencies = [
77
+ "proc-macro2",
78
+ "quote",
79
+ "unicode-ident",
80
+ ]
81
+
82
+ [[package]]
83
+ name = "unicode-ident"
84
+ version = "1.0.12"
85
+ source = "registry+https://github.com/rust-lang/crates.io-index"
86
+ checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b"
87
+
88
+ [[package]]
89
+ name = "wasm-bindgen"
90
+ version = "0.2.92"
91
+ source = "registry+https://github.com/rust-lang/crates.io-index"
92
+ checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8"
93
+ dependencies = [
94
+ "cfg-if",
95
+ "wasm-bindgen-macro",
96
+ ]
97
+
98
+ [[package]]
99
+ name = "wasm-bindgen-backend"
100
+ version = "0.2.92"
101
+ source = "registry+https://github.com/rust-lang/crates.io-index"
102
+ checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da"
103
+ dependencies = [
104
+ "bumpalo",
105
+ "log",
106
+ "once_cell",
107
+ "proc-macro2",
108
+ "quote",
109
+ "syn",
110
+ "wasm-bindgen-shared",
111
+ ]
112
+
113
+ [[package]]
114
+ name = "wasm-bindgen-macro"
115
+ version = "0.2.92"
116
+ source = "registry+https://github.com/rust-lang/crates.io-index"
117
+ checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726"
118
+ dependencies = [
119
+ "quote",
120
+ "wasm-bindgen-macro-support",
121
+ ]
122
+
123
+ [[package]]
124
+ name = "wasm-bindgen-macro-support"
125
+ version = "0.2.92"
126
+ source = "registry+https://github.com/rust-lang/crates.io-index"
127
+ checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7"
128
+ dependencies = [
129
+ "proc-macro2",
130
+ "quote",
131
+ "syn",
132
+ "wasm-bindgen-backend",
133
+ "wasm-bindgen-shared",
134
+ ]
135
+
136
+ [[package]]
137
+ name = "wasm-bindgen-shared"
138
+ version = "0.2.92"
139
+ source = "registry+https://github.com/rust-lang/crates.io-index"
140
+ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96"
141
+
142
+ [[package]]
143
+ name = "wasm_xml_parser"
144
+ version = "0.1.0"
145
+ dependencies = [
146
+ "quick-xml",
147
+ "wasm-bindgen",
148
+ "web-sys",
149
+ ]
150
+
151
+ [[package]]
152
+ name = "web-sys"
153
+ version = "0.3.69"
154
+ source = "registry+https://github.com/rust-lang/crates.io-index"
155
+ checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef"
156
+ dependencies = [
157
+ "js-sys",
158
+ "wasm-bindgen",
159
+ ]
@@ -1,16 +1,16 @@
1
- [package]
2
- name = "wasm_xml_parser"
3
- version = "0.1.0"
4
- authors = ["lowlighter"]
5
- edition = "2021"
6
- description = "WASM XML parser"
7
- repository = "https://github.com/lowlighter/libs"
8
- license = "MIT"
9
-
10
- [dependencies]
11
- quick-xml = "0.31"
12
- wasm-bindgen = "0.2"
13
- web-sys = { version = "0.3" }
14
-
15
- [lib]
16
- crate-type = ["cdylib", "rlib"]
1
+ [package]
2
+ name = "wasm_xml_parser"
3
+ version = "0.1.0"
4
+ authors = ["lowlighter"]
5
+ edition = "2021"
6
+ description = "WASM XML parser"
7
+ repository = "https://github.com/lowlighter/libs"
8
+ license = "MIT"
9
+
10
+ [dependencies]
11
+ quick-xml = "0.31"
12
+ wasm-bindgen = "0.2"
13
+ web-sys = { version = "0.3" }
14
+
15
+ [lib]
16
+ crate-type = ["cdylib", "rlib"]