File tree Expand file tree Collapse file tree 2 files changed +9
-13
lines changed Expand file tree Collapse file tree 2 files changed +9
-13
lines changed Original file line number Diff line number Diff line change 1
1
/**
2
- * @typedef {import('hast').Root } Root
3
- * @typedef {import('hast').Content } Content
4
- */
5
-
6
- /**
7
- * @typedef {Root | Content } Node
2
+ * @typedef {import('hast').Nodes } Nodes
8
3
*/
9
4
10
5
import { convertElement } from 'hast-util-is-element'
@@ -78,14 +73,15 @@ export function phrasing(value) {
78
73
( value . type === 'text' ||
79
74
basic ( value ) ||
80
75
embedded ( value ) ||
76
+ // @ts -expect-error: To do: update `hast-util-is-body-ok-link` in `rehype-minify`.
81
77
isBodyOkLink ( value ) ||
82
78
( meta ( value ) && hasProperty ( value , 'itemProp' ) ) )
83
79
)
84
80
}
85
81
86
82
/**
87
83
* @param {unknown } value
88
- * @returns {value is Node }
84
+ * @returns {value is Nodes }
89
85
*/
90
86
function node ( value ) {
91
87
// @ts -expect-error: looks like an object.
Original file line number Diff line number Diff line change 33
33
" index.js"
34
34
],
35
35
"dependencies" : {
36
- "@types/hast" : " ^2 .0.0" ,
37
- "hast-util-embedded" : " ^2 .0.0" ,
38
- "hast-util-has-property" : " ^2 .0.0" ,
36
+ "@types/hast" : " ^3 .0.0" ,
37
+ "hast-util-embedded" : " ^3 .0.0" ,
38
+ "hast-util-has-property" : " ^3 .0.0" ,
39
39
"hast-util-is-body-ok-link" : " ^2.0.0" ,
40
- "hast-util-is-element" : " ^2 .0.0"
40
+ "hast-util-is-element" : " ^3 .0.0"
41
41
},
42
42
"devDependencies" : {
43
43
"@types/node" : " ^20.0.0" ,
44
44
"c8" : " ^8.0.0" ,
45
- "hastscript" : " ^7 .0.0" ,
45
+ "hastscript" : " ^8 .0.0" ,
46
46
"prettier" : " ^3.0.0" ,
47
47
"remark-cli" : " ^11.0.0" ,
48
48
"remark-preset-wooorm" : " ^9.0.0" ,
49
49
"type-coverage" : " ^2.0.0" ,
50
50
"typescript" : " ^5.0.0" ,
51
- "unist-builder" : " ^3 .0.0" ,
51
+ "unist-builder" : " ^4 .0.0" ,
52
52
"xo" : " ^0.55.0"
53
53
},
54
54
"scripts" : {
You can’t perform that action at this time.
0 commit comments