File tree 1 file changed +6
-4
lines changed
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 2
2
* @typedef {import('mdast').Root|import('mdast').Content } Node
3
3
*
4
4
* @typedef Options
5
+ * Configuration (optional).
5
6
* @property {boolean } [includeImageAlt=true]
7
+ * Whether to use `alt` for `image`s.
6
8
*/
7
9
8
10
/**
9
- * Get the text content of a node.
10
- * Prefer the node’s plain-text fields, otherwise serialize its children,
11
+ * Get the text content of a node or list of nodes .
12
+ * Prefers the node’s plain-text fields, otherwise serializes its children,
11
13
* and if the given value is an array, serialize the nodes in it.
12
14
*
13
15
* @param {unknown } value
@@ -36,12 +38,12 @@ function one(value, includeImageAlt) {
36
38
}
37
39
38
40
/**
39
- * @param {Array. <unknown> } values
41
+ * @param {Array<unknown> } values
40
42
* @param {boolean } includeImageAlt
41
43
* @returns {string }
42
44
*/
43
45
function all ( values , includeImageAlt ) {
44
- /** @type {Array. <string> } */
46
+ /** @type {Array<string> } */
45
47
const result = [ ]
46
48
let index = - 1
47
49
You can’t perform that action at this time.
0 commit comments