hyper-dom-expressions 0.33.4 → 0.33.7

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.
@@ -66,7 +66,17 @@ function createHyperScript(r) {
66
66
  }
67
67
  const d = Object.getOwnPropertyDescriptors(props);
68
68
  for (const k in d) {
69
- if (typeof d[k].value === "function" && !d[k].value.length) r.dynamicProperty(props, k);
69
+ if (Array.isArray(d[k].value)) {
70
+ const list = d[k].value;
71
+ props[k] = () => {
72
+ for (let i = 0; i < list.length; i++) {
73
+ while (list[i][$ELEMENT]) list[i] = list[i]();
74
+ }
75
+ return list;
76
+ };
77
+ r.dynamicProperty(props, k);
78
+ } else if (typeof d[k].value === "function" && !d[k].value.length)
79
+ r.dynamicProperty(props, k);
70
80
  }
71
81
  e = r.createComponent(l, props);
72
82
  args = [];
@@ -70,7 +70,17 @@ function createHyperScript(r) {
70
70
  }
71
71
  const d = Object.getOwnPropertyDescriptors(props);
72
72
  for (const k in d) {
73
- if (typeof d[k].value === "function" && !d[k].value.length) r.dynamicProperty(props, k);
73
+ if (Array.isArray(d[k].value)) {
74
+ const list = d[k].value;
75
+ props[k] = () => {
76
+ for (let i = 0; i < list.length; i++) {
77
+ while (list[i][$ELEMENT]) list[i] = list[i]();
78
+ }
79
+ return list;
80
+ };
81
+ r.dynamicProperty(props, k);
82
+ } else if (typeof d[k].value === "function" && !d[k].value.length)
83
+ r.dynamicProperty(props, k);
74
84
  }
75
85
  e = r.createComponent(l, props);
76
86
  args = [];
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "hyper-dom-expressions",
3
3
  "description": "A Fine-Grained Rendering Runtime API using HyperScript",
4
- "version": "0.33.4",
4
+ "version": "0.33.7",
5
5
  "author": "Ryan Carniato",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -18,7 +18,7 @@
18
18
  "test:coverage": "npm run build && jest --coverage"
19
19
  },
20
20
  "devDependencies": {
21
- "dom-expressions": "^0.33.4"
21
+ "dom-expressions": "^0.33.7"
22
22
  },
23
- "gitHead": "f0e8489ca3ca8a22536c7736e07acc71b1006a4a"
23
+ "gitHead": "adea58b5d73a28af4f95afcb4d05f2418433e696"
24
24
  }