We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
readme.md
1 parent 1477ff7 commit a52745cCopy full SHA for a52745c
readme.md
@@ -40,11 +40,20 @@ Yields:
40
41
## API
42
43
-### `toParse5(node)`
+### `toParse5(tree[, space])`
44
45
Transform a [HAST Node][node] to an `ASTNode` according to the default
46
Parse5 adapter.
47
48
+###### `space`
49
+
50
+Whether the root of the given tree is in the `'html'` or `'svg'` space (enum,
51
+`'svg'` or `'html'`, default: `'html'`).
52
53
+If an `svg` element is found in the HTML space, `toParse5` automatically
54
+switches to the SVG space when entering the element, and switches back when
55
+leaving.
56
57
## Contribute
58
59
See [`contributing.md` in `syntax-tree/hast`][contributing] for ways to get
0 commit comments