@thi.ng/rdom 1.7.17 → 1.7.19
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/CHANGELOG.md +7 -1
- package/README.md +2 -2
- package/compile.js +1 -1
- package/dom.js +2 -3
- package/package.json +10 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
-
- **Last updated**:
|
|
3
|
+
- **Last updated**: 2025-01-14T12:23:33Z
|
|
4
4
|
- **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
|
|
5
5
|
|
|
6
6
|
All notable changes to this project will be documented in this file.
|
|
@@ -9,6 +9,12 @@ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelin
|
|
|
9
9
|
**Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
|
|
10
10
|
and/or version bumps of transitive dependencies.
|
|
11
11
|
|
|
12
|
+
### [1.7.19](https://github.com/thi-ng/umbrella/tree/@thi.ng/rdom@1.7.19) (2025-01-14)
|
|
13
|
+
|
|
14
|
+
#### ♻️ Refactoring
|
|
15
|
+
|
|
16
|
+
- use optional chaining & nullish coalescing ([c5a0a13](https://github.com/thi-ng/umbrella/commit/c5a0a13))
|
|
17
|
+
|
|
12
18
|
### [1.7.13](https://github.com/thi-ng/umbrella/tree/@thi.ng/rdom@1.7.13) (2024-11-24)
|
|
13
19
|
|
|
14
20
|
#### ⏱ Performance improvements
|
package/README.md
CHANGED
|
@@ -315,7 +315,7 @@ Browser ESM import:
|
|
|
315
315
|
|
|
316
316
|
[JSDelivr documentation](https://www.jsdelivr.com/)
|
|
317
317
|
|
|
318
|
-
Package sizes (brotli'd, pre-treeshake): ESM: 4.
|
|
318
|
+
Package sizes (brotli'd, pre-treeshake): ESM: 4.29 KB
|
|
319
319
|
|
|
320
320
|
## Dependencies
|
|
321
321
|
|
|
@@ -501,4 +501,4 @@ If this project contributes to an academic publication, please cite it as:
|
|
|
501
501
|
|
|
502
502
|
## License
|
|
503
503
|
|
|
504
|
-
© 2020 -
|
|
504
|
+
© 2020 - 2025 Karsten Schmidt // Apache License 2.0
|
package/compile.js
CHANGED
|
@@ -56,7 +56,7 @@ const __complexComponent = (tree) => ({
|
|
|
56
56
|
await c.unmount();
|
|
57
57
|
}
|
|
58
58
|
}
|
|
59
|
-
this.subs
|
|
59
|
+
this.subs?.forEach((s) => s.unsubscribe());
|
|
60
60
|
this.el && $remove(this.el);
|
|
61
61
|
this.el = this.children = this.subs = void 0;
|
|
62
62
|
},
|
package/dom.js
CHANGED
|
@@ -37,8 +37,7 @@ const $treeTag = (tree, parent, idx) => {
|
|
|
37
37
|
if (n === 3 && (isString(body) || isNumber(body))) {
|
|
38
38
|
const tmp = /^\w+/.exec(tag);
|
|
39
39
|
if (tmp && NO_SPANS[tmp[0]]) {
|
|
40
|
-
|
|
41
|
-
return parent;
|
|
40
|
+
return $el(tag, attribs, body, parent, idx);
|
|
42
41
|
}
|
|
43
42
|
}
|
|
44
43
|
parent = $el(tag, attribs, null, parent, idx);
|
|
@@ -85,7 +84,7 @@ const $comment = (body, parent, idx = -1) => {
|
|
|
85
84
|
const $addChild = (parent, child, idx = -1) => {
|
|
86
85
|
isNumber(idx) ? idx < 0 || idx >= parent.children.length ? parent.appendChild(child) : parent.insertBefore(child, parent.children[idx]) : parent.insertBefore(child, idx);
|
|
87
86
|
};
|
|
88
|
-
const $remove = (el) => el
|
|
87
|
+
const $remove = (el) => el?.remove();
|
|
89
88
|
const $moveTo = (newParent, el, idx = -1) => {
|
|
90
89
|
$remove(el);
|
|
91
90
|
$addChild(newParent, el, idx);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/rdom",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.19",
|
|
4
4
|
"description": "Lightweight, reactive, VDOM-less UI/DOM components with async lifecycle and @thi.ng/hiccup compatible",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -41,14 +41,14 @@
|
|
|
41
41
|
"tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@thi.ng/api": "^8.11.
|
|
45
|
-
"@thi.ng/checks": "^3.6.
|
|
46
|
-
"@thi.ng/errors": "^2.5.
|
|
47
|
-
"@thi.ng/hiccup": "^5.2.
|
|
48
|
-
"@thi.ng/paths": "^5.1.
|
|
49
|
-
"@thi.ng/prefixes": "^2.3.
|
|
50
|
-
"@thi.ng/rstream": "^9.2.
|
|
51
|
-
"@thi.ng/strings": "^3.
|
|
44
|
+
"@thi.ng/api": "^8.11.16",
|
|
45
|
+
"@thi.ng/checks": "^3.6.19",
|
|
46
|
+
"@thi.ng/errors": "^2.5.22",
|
|
47
|
+
"@thi.ng/hiccup": "^5.2.23",
|
|
48
|
+
"@thi.ng/paths": "^5.1.97",
|
|
49
|
+
"@thi.ng/prefixes": "^2.3.33",
|
|
50
|
+
"@thi.ng/rstream": "^9.2.4",
|
|
51
|
+
"@thi.ng/strings": "^3.9.0"
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
54
|
"@microsoft/api-extractor": "^7.48.1",
|
|
@@ -150,5 +150,5 @@
|
|
|
150
150
|
],
|
|
151
151
|
"year": 2020
|
|
152
152
|
},
|
|
153
|
-
"gitHead": "
|
|
153
|
+
"gitHead": "6542b842120bef47cc18d45a1b1db68307a7f04b\n"
|
|
154
154
|
}
|