@@ -54,7 +54,7 @@ turning line endings into `<br>`s
54
54
## Install
55
55
56
56
This package is [ ESM only] [ esm ] .
57
- In Node.js (version 14.14+ and 16.0 +), install with [ npm] [ ] :
57
+ In Node.js (version 16 +), install with [ npm] [ ] :
58
58
59
59
``` sh
60
60
npm install hast-util-to-text
@@ -102,7 +102,7 @@ Delta echo foxtrot.
102
102
103
103
## API
104
104
105
- This package exports the identifier [ ` toText ` ] [ totext ] .
105
+ This package exports the identifier [ ` toText ` ] [ api-to-text ] .
106
106
There is no default export.
107
107
108
108
### ` toText(tree[, options]) `
@@ -113,7 +113,7 @@ Get the plain-text value of a node.
113
113
114
114
* ` tree ` ([ ` Node ` ] [ node ] )
115
115
— tree to turn into text
116
- * ` options ` ([ ` Options ` ] [ options ] , optional)
116
+ * ` options ` ([ ` Options ` ] [ api- options] , optional)
117
117
— configuration
118
118
119
119
###### Returns
@@ -149,7 +149,7 @@ Configuration (TypeScript type).
149
149
150
150
##### Fields
151
151
152
- * ` whitespace ` ([ ` Whitespace ` ] [ whitespace ] , default: ` 'normal' ` )
152
+ * ` whitespace ` ([ ` Whitespace ` ] [ api- whitespace] , default: ` 'normal' ` )
153
153
— default whitespace setting to use
154
154
155
155
### ` Whitespace `
@@ -159,21 +159,24 @@ Valid and useful whitespace values (from [CSS][]) (TypeScript type).
159
159
##### Type
160
160
161
161
``` ts
162
- type Whitespace = ' normal' | ' pre ' | ' nowrap ' | ' pre-wrap'
162
+ type Whitespace = ' normal' | ' nowrap ' | ' pre ' | ' pre-wrap'
163
163
` ` `
164
164
165
165
## Types
166
166
167
167
This package is fully typed with [TypeScript][].
168
- It exports the additional types [ ` Options ` ][options] and
169
- [ ` Whitespace ` ][whitespace].
168
+ It exports the additional types [ ` Options ` ][api- options] and
169
+ [ ` Whitespace ` ][api- whitespace].
170
170
171
171
## Compatibility
172
172
173
- Projects maintained by the unified collective are compatible with all maintained
173
+ Projects maintained by the unified collective are compatible with maintained
174
174
versions of Node.js.
175
- As of now, that is Node.js 14.14+ and 16.0+.
176
- Our projects sometimes work with older versions, but this is not guaranteed.
175
+
176
+ When we cut a new major release, we drop support for unmaintained versions of
177
+ Node.
178
+ This means we try to keep the current release line, ` hast -util -to -text @^3 ` ,
179
+ compatible with Node.js 12.
177
180
178
181
## Security
179
182
@@ -217,9 +220,9 @@ abide by its terms.
217
220
218
221
[downloads]: https://www.npmjs.com/package/hast-util-to-text
219
222
220
- [size-badge]: https://img.shields.io/bundlephobia/minzip/ hast-util-to-text.svg
223
+ [size-badge]: https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q= hast-util-to-text
221
224
222
- [size]: https://bundlephobia .com/result?p =hast-util-to-text
225
+ [size]: https://bundlejs .com/?q =hast-util-to-text
223
226
224
227
[sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg
225
228
@@ -273,8 +276,8 @@ abide by its terms.
273
276
274
277
[xss]: https://en.wikipedia.org/wiki/Cross-site_scripting
275
278
276
- [totext ]: #totexttree-options
279
+ [api-to-text ]: #totexttree-options
277
280
278
- [options]: #options
281
+ [api- options]: #options
279
282
280
- [whitespace]: #whitespace
283
+ [api- whitespace]: #whitespace
0 commit comments