1
1
import type { Program } from 'estree-jsx'
2
- import type { Literal as HastLiteral } from 'hast'
3
- import type { Literal as MdastLiteral } from 'mdast'
2
+ import type { Data as HastData , Literal as HastLiteral } from 'hast'
3
+ import type { Data as MdastData , Literal as MdastLiteral } from 'mdast'
4
4
5
5
export {
6
6
mdxExpressionFromMarkdown ,
@@ -17,14 +17,19 @@ export interface MdxFlowExpression extends MdastLiteral {
17
17
type : 'mdxFlowExpression'
18
18
19
19
/**
20
- * Data.
20
+ * Data associated with the mdast MDX expression (flow) .
21
21
*/
22
- data ?: {
23
- /**
24
- * Program node from estree.
25
- */
26
- estree ?: Program | null | undefined
27
- } & MdastLiteral [ 'data' ]
22
+ data ?: MdxFlowExpressionData | undefined
23
+ }
24
+
25
+ /**
26
+ * Info associated with mdast MDX expression (flow) nodes by the ecosystem.
27
+ */
28
+ export interface MdxFlowExpressionData extends MdastData {
29
+ /**
30
+ * Program node from estree.
31
+ */
32
+ estree ?: Program | null | undefined
28
33
}
29
34
30
35
/**
@@ -37,14 +42,19 @@ export interface MdxTextExpression extends MdastLiteral {
37
42
type : 'mdxTextExpression'
38
43
39
44
/**
40
- * Data.
45
+ * Data associated with the mdast MDX expression (text) .
41
46
*/
42
- data ?: {
43
- /**
44
- * Program node from estree.
45
- */
46
- estree ?: Program | null | undefined
47
- } & MdastLiteral [ 'data' ]
47
+ data ?: MdxTextExpressionData | undefined
48
+ }
49
+
50
+ /**
51
+ * Info associated with mdast MDX expression (text) nodes by the ecosystem.
52
+ */
53
+ export interface MdxTextExpressionData extends MdastData {
54
+ /**
55
+ * Program node from estree.
56
+ */
57
+ estree ?: Program | null | undefined
48
58
}
49
59
50
60
/**
@@ -57,14 +67,19 @@ export interface MdxFlowExpressionHast extends HastLiteral {
57
67
type : 'mdxFlowExpression'
58
68
59
69
/**
60
- * Data.
70
+ * Data associated with the hast MDX expression (flow) .
61
71
*/
62
- data ?: {
63
- /**
64
- * Program node from estree.
65
- */
66
- estree ?: Program | null | undefined
67
- } & HastLiteral [ 'data' ]
72
+ data ?: MdxFlowExpressionHastData | undefined
73
+ }
74
+
75
+ /**
76
+ * Info associated with hast MDX expression (flow) nodes by the ecosystem.
77
+ */
78
+ export interface MdxFlowExpressionHastData extends HastData {
79
+ /**
80
+ * Program node from estree.
81
+ */
82
+ estree ?: Program | null | undefined
68
83
}
69
84
70
85
/**
@@ -77,14 +92,19 @@ export interface MdxTextExpressionHast extends HastLiteral {
77
92
type : 'mdxTextExpression'
78
93
79
94
/**
80
- * Data.
95
+ * Data associated with the hast MDX expression (text) .
81
96
*/
82
- data ?: {
83
- /**
84
- * Program node from estree.
85
- */
86
- estree ?: Program | null | undefined
87
- } & HastLiteral [ 'data' ]
97
+ data ?: MdxTextExpressionHastData | undefined
98
+ }
99
+
100
+ /**
101
+ * Info associated with hast MDX expression (text) nodes by the ecosystem.
102
+ */
103
+ export interface MdxTextExpressionHastData extends HastData {
104
+ /**
105
+ * Program node from estree.
106
+ */
107
+ estree ?: Program | null | undefined
88
108
}
89
109
90
110
// Add nodes to mdast content.
0 commit comments