Skip to content

Commit f0e9767

Browse files
committed
Update hast-to-hyperscript
1 parent d753ed9 commit f0e9767

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Diff for: index.js

+5
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,11 @@ function element(node, schema) {
7575
for (key in attrs) {
7676
info = find(schema, key)
7777
attr = attrs[key]
78+
79+
if (attr === false || (info.boolean && !attr)) {
80+
continue
81+
}
82+
7883
value = {name: key, value: attr === true ? '' : String(attr)}
7984

8085
if (info.space && ignoredSpaces.indexOf(info.space) === -1) {

Diff for: package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"index.js"
2020
],
2121
"dependencies": {
22-
"hast-to-hyperscript": "^6.0.0",
22+
"hast-to-hyperscript": "^7.0.0",
2323
"property-information": "^5.0.0",
2424
"web-namespaces": "^1.0.0",
2525
"xtend": "^4.0.1",

0 commit comments

Comments
 (0)