Skip to content

Commit f7756af

Browse files
committed
Refactor prose
1 parent c66f7c7 commit f7756af

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

readme.md

+5-6
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
[![Backers][backers-badge]][collective]
99
[![Chat][chat-badge]][chat]
1010

11-
[**mdast**][mdast] utility to get the plain text content of a node.
11+
**[mdast][]** utility to get the plain text content of a node.
1212

1313
## Install
1414

@@ -36,21 +36,20 @@ console.log(toString(tree)) // => 'Some emphasis, importance, and code.'
3636

3737
### `toString(node)`
3838

39-
Get the text content of a [node][].
39+
Get the text content of a [node][] or list of nodes.
4040

4141
The algorithm checks `value` of `node`, then `alt`, and finally `title`.
4242
If no value is found, the algorithm checks the children of `node` and joins them
4343
(without spaces or newlines).
44-
If the given node is in fact a list of nodes, serializes them.
4544

4645
> This is not a markdown to plain-text library.
4746
> Use [`strip-markdown`][strip-markdown] for that.
4847
4948
## Security
5049

51-
Use of `mdast-util-to-string` does not involve [**hast**][hast], user content,
52-
or change the tree, so there are no openings for
53-
[cross-site scripting (XSS)][xss] attacks.
50+
Use of `mdast-util-to-string` does not involve **[hast][]**, user content, or
51+
change the tree, so there are no openings for [cross-site scripting (XSS)][xss]
52+
attacks.
5453

5554
## Related
5655

0 commit comments

Comments
 (0)