26
26
27
27
## What is this?
28
28
29
- This utility can be used to check if a node is said to be [ generated] [ ] .
29
+ This utility can be used to check if a node is said to be
30
+ [ generated] [ generated-term ] .
30
31
31
32
## When should I use this?
32
33
@@ -43,7 +44,7 @@ To display positional info to users, use
43
44
## Install
44
45
45
46
This package is [ ESM only] [ esm ] .
46
- In Node.js (version 12.20+, 14.14+, 16.0+, 18 .0+), install with [ npm] [ ] :
47
+ In Node.js (version 14.14+ and 16 .0+), install with [ npm] [ ] :
47
48
48
49
``` sh
49
50
npm install unist-util-generated
@@ -52,14 +53,14 @@ npm install unist-util-generated
52
53
In Deno with [ ` esm.sh ` ] [ esmsh ] :
53
54
54
55
``` js
55
- import {generated } from " https://esm.sh/unist-util-generated@2"
56
+ import {generated } from ' https://esm.sh/unist-util-generated@2'
56
57
```
57
58
58
59
In browsers with [ ` esm.sh ` ] [ esmsh ] :
59
60
60
61
``` html
61
62
<script type =" module" >
62
- import {generated } from " https://esm.sh/unist-util-generated@2?bundle"
63
+ import {generated } from ' https://esm.sh/unist-util-generated@2?bundle'
63
64
</script >
64
65
```
65
66
@@ -79,16 +80,21 @@ generated({
79
80
80
81
## API
81
82
82
- This package exports the identifier ` generated ` .
83
+ This package exports the identifier [ ` generated ` ] [ generated ] .
83
84
There is no default export.
84
85
85
86
### ` generated(node) `
86
87
87
- Check if ` node ` ([ ` Node ` ] [ node ] ) is * [ generated] [ ] * .
88
+ Check if ` node ` is generated.
89
+
90
+ ###### Parameters
91
+
92
+ * ` node ` ([ ` Node ` ] [ node ] )
93
+ — node to check
88
94
89
95
###### Returns
90
96
91
- Whether ` node ` is generated (` boolean ` ).
97
+ Whether ` node ` is generated (does not have positional info) ( ` boolean ` ).
92
98
93
99
## Types
94
100
@@ -99,7 +105,7 @@ It exports no additional types.
99
105
100
106
Projects maintained by the unified collective are compatible with all maintained
101
107
versions of Node.js.
102
- As of now, that is Node.js 12.20+, 14.14+, 16.0+, and 18 .0+.
108
+ As of now, that is Node.js 14.14+ and 16 .0+.
103
109
Our projects sometimes work with older versions, but this is not guaranteed.
104
110
105
111
## Related
@@ -179,8 +185,10 @@ abide by its terms.
179
185
180
186
[ node ] : https://github.com/syntax-tree/unist#node
181
187
182
- [ generated ] : https://github.com/syntax-tree/unist#generated
188
+ [ generated-term ] : https://github.com/syntax-tree/unist#generated
183
189
184
190
[ unist-util-position ] : https://github.com/syntax-tree/unist-util-position
185
191
186
192
[ unist-util-stringify-position ] : https://github.com/syntax-tree/unist-util-stringify-position
193
+
194
+ [ generated ] : #generatednode
0 commit comments