Comparing version
@@ -0,1 +1,4 @@ | ||
# 7.0.1 | ||
- #61 Support rich data properties | ||
# 7.0.0 | ||
@@ -2,0 +5,0 @@ - Breaking change: |
@@ -374,2 +374,4 @@ const keys = Object.keys | ||
} | ||
} else if (isObject(value)) { | ||
node[key] = value | ||
} else if (value === true) { | ||
@@ -376,0 +378,0 @@ attr(node, key, "") |
{ | ||
"name": "jsx-dom", | ||
"version": "7.0.1", | ||
"version": "7.0.2", | ||
"description": "JSX to document.createElement.", | ||
"main": "index.js", | ||
"module": "index.js", | ||
"files": [ | ||
"cjs", | ||
"esm", | ||
"index.d.ts" | ||
], | ||
"keywords": [ | ||
@@ -8,0 +13,0 @@ "jsx", |
@@ -163,2 +163,15 @@ # jsx-dom | ||
5. Rich data jsx properties are accepted, but populated as properties rather than dom attributes. | ||
```jsx | ||
class MyCustomElement extends HTMLElement { | ||
constructor() { | ||
super(); | ||
} | ||
} | ||
customElements.define('my-custom-element', MyCustomElement); | ||
const richData = { foo: 'bar' } | ||
return <my-custom-element richData={richData} /> | ||
``` | ||
### Functional and class components | ||
@@ -165,0 +178,0 @@ |
313
4.33%92399
-6.62%6
-53.85%2360
-11.21%