88[ ![ Backers] [ backers-badge ]] [ collective ]
99[ ![ Chat] [ chat-badge ]] [ chat ]
1010
11- [ hast] [ ] utility to check if a node is [ * script-supporting* ] [ spec ] .
11+ [ hast] [ ] utility to check if a node is a [ * script-supporting* element ] [ spec ] .
1212
1313## Contents
1414
1717* [ Install] ( #install )
1818* [ Use] ( #use )
1919* [ API] ( #api )
20- * [ ` scriptSupporting(node ) ` ] ( #scriptsupportingnode )
20+ * [ ` scriptSupporting(value ) ` ] ( #scriptsupportingvalue )
2121* [ Types] ( #types )
2222* [ Compatibility] ( #compatibility )
2323* [ Security] ( #security )
@@ -38,7 +38,7 @@ looking for!
3838## Install
3939
4040This package is [ ESM only] [ esm ] .
41- In Node.js (version 12.20+, 14.14+, 16.0+, or 18 .0+), install with [ npm] [ ] :
41+ In Node.js (version 14.14+ and 16 .0+), install with [ npm] [ ] :
4242
4343``` sh
4444npm install hast-util-script-supporting
@@ -79,20 +79,22 @@ scriptSupporting({
7979
8080## API
8181
82- This package exports the identifier ` scriptSupporting ` .
82+ This package exports the identifier [ ` scriptSupporting ` ] [ scriptsupporting ] .
8383There is no default export.
8484
85- ### ` scriptSupporting(node ) `
85+ ### ` scriptSupporting(value ) `
8686
87- Check if the given value is a [ * script-supporting* ] [ spec ] [ * element* ] [ element ] .
87+ Check if the given value is a [ * script-supporting* element] [ spec ] .
8888
8989###### Parameters
9090
91- * ` node ` ([ ` Node ` ] [ node ] ) — node to check
91+ * ` value ` (` unknown ` ) — thing to check (typically [ ` Node ` ] [ node ] )
9292
9393###### Returns
9494
95- Whether the ` value ` is script-supporting (` boolean ` ).
95+ Whether ` value ` is a script-supporting element (` boolean ` ).
96+
97+ The elements ` script ` and ` template ` are script-supporting.
9698
9799## Types
98100
@@ -103,7 +105,7 @@ It exports no additional types.
103105
104106Projects maintained by the unified collective are compatible with all maintained
105107versions of Node.js.
106- 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+.
107109Our projects sometimes work with older versions, but this is not guaranteed.
108110
109111## Security
@@ -206,12 +208,12 @@ abide by its terms.
206208
207209[ coc ] : https://github.com/syntax-tree/.github/blob/main/code-of-conduct.md
208210
209- [ spec ] : https://html.spec.whatwg.org/#script-supporting-elements
211+ [ spec ] : https://html.spec.whatwg.org/multipage/dom.html #script-supporting-elements
210212
211213[ hast ] : https://github.com/syntax-tree/hast
212214
213- [ element ] : https://github.com/syntax-tree/hast#element
214-
215215[ node ] : https://github.com/syntax-tree/hast#nodes
216216
217217[ xss ] : https://en.wikipedia.org/wiki/Cross-site_scripting
218+
219+ [ scriptsupporting ] : #scriptsupportingvalue
0 commit comments