@@ -48,7 +48,7 @@ You can instead use [`unist-builder`][u] when creating any unist nodes and
48
48
## Install
49
49
50
50
This package is [ ESM only] [ esm ] .
51
- In Node.js (version 14.14+ and 16.0 +), install with [ npm] [ ] :
51
+ In Node.js (version 16 +), install with [ npm] [ ] :
52
52
53
53
``` sh
54
54
npm install xastscript
@@ -191,7 +191,7 @@ Yields:
191
191
192
192
## API
193
193
194
- This package exports the identifier [ ` x ` ] [ x ] .
194
+ This package exports the identifier [ ` x ` ] [ api- x] .
195
195
There is no default export.
196
196
197
197
The export map supports the automatic JSX runtime.
@@ -220,15 +220,15 @@ When nullish, a [`Root`][root] is built instead.
220
220
221
221
###### ` attributes `
222
222
223
- Attributes of the element ([ ` Attributes ` ] [ attributes ] , optional).
223
+ Attributes of the element ([ ` Attributes ` ] [ api- attributes] , optional).
224
224
225
225
###### ` children `
226
226
227
- Children of the node ([ ` Child ` ] [ child ] or ` Array< Child> ` , optional).
227
+ Children of the node ([ ` Array< Child> ` ] [ api- child] or ` Child ` , optional).
228
228
229
229
##### Returns
230
230
231
- Created tree ([ ` Result ` ] [ result ] ).
231
+ Created tree ([ ` Result ` ] [ api- result] ).
232
232
233
233
[ ` Element ` ] [ element ] when a ` name ` is passed, otherwise [ ` Root ` ] [ root ] .
234
234
@@ -294,7 +294,7 @@ You should use the automatic JSX runtime set to `xastscript`.
294
294
The Use example above (omitting the second) can then be written like so:
295
295
296
296
` ` ` jsx
297
- /** @jsxImportSource x */
297
+ /** @jsxImportSource xastscript */
298
298
299
299
import {u } from ' unist-builder'
300
300
@@ -321,15 +321,18 @@ console.log(
321
321
## Types
322
322
323
323
This package is fully typed with [ TypeScript] [ ] .
324
- It exports the additional types [ ` Attributes ` ] [ attributes ] , [ ` Child ` ] [ child ] ,
325
- and [ ` Result ` ] [ result ] .
324
+ It exports the additional types [ ` Attributes ` ] [ api- attributes] ,
325
+ [ ` Child ` ] [ api-child ] , and [ ` Result ` ] [ api- result] .
326
326
327
327
## Compatibility
328
328
329
- Projects maintained by the unified collective are compatible with all maintained
329
+ Projects maintained by the unified collective are compatible with maintained
330
330
versions of Node.js.
331
- As of now, that is Node.js 14.14+ and 16.0+.
332
- Our projects sometimes work with older versions, but this is not guaranteed.
331
+
332
+ When we cut a new major release, we drop support for unmaintained versions of
333
+ Node.
334
+ This means we try to keep the current release line, ` xastscript@^3 ` , compatible
335
+ with Node.js 12.
333
336
334
337
## Security
335
338
@@ -376,9 +379,9 @@ abide by its terms.
376
379
377
380
[ downloads ] : https://www.npmjs.com/package/xastscript
378
381
379
- [ size-badge ] : https://img.shields.io/bundlephobia/minzip/xastscript.svg
382
+ [ size-badge ] : https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q=xastscript
380
383
381
- [ size ] : https://bundlephobia .com/result?p =xastscript
384
+ [ size ] : https://bundlejs .com/?q =xastscript
382
385
383
386
[ sponsors-badge ] : https://opencollective.com/unified/sponsors/badge.svg
384
387
@@ -422,10 +425,10 @@ abide by its terms.
422
425
423
426
[ h ] : https://github.com/syntax-tree/hastscript
424
427
425
- [ x ] : #xname-attributes-children
428
+ [ api- x] : #xname-attributes-children
426
429
427
- [ attributes ] : #attributes-1
430
+ [ api- attributes] : #attributes-1
428
431
429
- [ child ] : #child
432
+ [ api- child] : #child
430
433
431
- [ result ] : #result
434
+ [ api- result] : #result
0 commit comments