@kubb/renderer-jsx 5.0.0-alpha.73 → 5.0.0-beta.75
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -1
- package/dist/jsx-dev-runtime.d.ts +2 -2
- package/dist/{jsx-namespace-DdqdFHqm.d.ts → jsx-namespace-CNp0arTN.d.ts} +2 -2
- package/dist/jsx-runtime.d.ts +2 -2
- package/dist/{types-BEu94Tb3.d.ts → types-nAFMiWFw.d.ts} +33 -41
- package/dist/types.d.ts +1 -1
- package/package.json +2 -2
- package/src/types.ts +32 -40
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as __name } from "./chunk-Bb7HlUDG.js";
|
|
2
|
-
import { a as JSDoc, h as KubbReactNode, m as KubbReactElement, o as Key } from "./types-
|
|
2
|
+
import { a as JSDoc, h as KubbReactNode, m as KubbReactElement, o as Key } from "./types-nAFMiWFw.js";
|
|
3
3
|
import { ExportNode, FileNode, ImportNode, SourceNode } from "@kubb/ast";
|
|
4
4
|
import * as _$react from "react";
|
|
5
5
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as __name } from "./chunk-Bb7HlUDG.js";
|
|
2
|
-
import { h as KubbReactNode, m as KubbReactElement } from "./types-
|
|
3
|
-
import { t as JSX } from "./jsx-namespace-
|
|
2
|
+
import { h as KubbReactNode, m as KubbReactElement } from "./types-nAFMiWFw.js";
|
|
3
|
+
import { t as JSX } from "./jsx-namespace-CNp0arTN.js";
|
|
4
4
|
import * as _$react from "react";
|
|
5
5
|
import * as React$1 from "react/jsx-runtime";
|
|
6
6
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as __name } from "./chunk-Bb7HlUDG.js";
|
|
2
|
-
import { _ as KubbTextProps, c as KubbConstProps, d as KubbFunctionProps, f as KubbImportProps, g as KubbSourceProps, h as KubbReactNode, l as KubbExportProps, m as KubbReactElement, p as KubbJsxProps, s as KubbArrowFunctionProps, u as KubbFileProps, v as KubbTypeProps, y as LineBreakProps } from "./types-
|
|
2
|
+
import { _ as KubbTextProps, c as KubbConstProps, d as KubbFunctionProps, f as KubbImportProps, g as KubbSourceProps, h as KubbReactNode, l as KubbExportProps, m as KubbReactElement, p as KubbJsxProps, s as KubbArrowFunctionProps, u as KubbFileProps, v as KubbTypeProps, y as LineBreakProps } from "./types-nAFMiWFw.js";
|
|
3
3
|
import React from "react";
|
|
4
4
|
|
|
5
5
|
//#region src/jsx-namespace.d.ts
|
|
@@ -36,4 +36,4 @@ declare namespace JSX$1 {
|
|
|
36
36
|
}
|
|
37
37
|
//#endregion
|
|
38
38
|
export { JSX$1 as t };
|
|
39
|
-
//# sourceMappingURL=jsx-namespace-
|
|
39
|
+
//# sourceMappingURL=jsx-namespace-CNp0arTN.d.ts.map
|
package/dist/jsx-runtime.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as __name } from "./chunk-Bb7HlUDG.js";
|
|
2
|
-
import { h as KubbReactNode, m as KubbReactElement } from "./types-
|
|
3
|
-
import { t as JSX } from "./jsx-namespace-
|
|
2
|
+
import { h as KubbReactNode, m as KubbReactElement } from "./types-nAFMiWFw.js";
|
|
3
|
+
import { t as JSX } from "./jsx-namespace-CNp0arTN.js";
|
|
4
4
|
import * as _$react from "react";
|
|
5
5
|
import * as React$1 from "react/jsx-runtime";
|
|
6
6
|
|
|
@@ -4,13 +4,12 @@ import React, { JSX, ReactNode } from "react";
|
|
|
4
4
|
|
|
5
5
|
//#region src/types.d.ts
|
|
6
6
|
/**
|
|
7
|
-
* React
|
|
8
|
-
* Used to uniquely identify elements in lists and conditional renders.
|
|
7
|
+
* Unique identifier for a React element in lists or conditional renders.
|
|
9
8
|
*/
|
|
10
9
|
type Key = string | number | bigint;
|
|
11
10
|
/**
|
|
12
|
-
*
|
|
13
|
-
* Each name maps to a corresponding AST node type
|
|
11
|
+
* Custom element names recognized by the Kubb JSX renderer.
|
|
12
|
+
* Each name maps to a corresponding AST node type in the generated code.
|
|
14
13
|
*/
|
|
15
14
|
type ElementNames = 'br' | 'div' | 'indent' | 'dedent' | 'kubb-jsx' | 'kubb-text' | 'kubb-file' | 'kubb-source' | 'kubb-import' | 'kubb-export' | 'kubb-function' | 'kubb-arrow-function' | 'kubb-const' | 'kubb-type' | 'kubb-root' | 'kubb-app';
|
|
16
15
|
type Node = {
|
|
@@ -18,23 +17,19 @@ type Node = {
|
|
|
18
17
|
internal_static?: boolean;
|
|
19
18
|
};
|
|
20
19
|
/**
|
|
21
|
-
* Allowed attribute value types
|
|
22
|
-
* Corresponds to the range of prop values JSX components may pass to intrinsic elements.
|
|
20
|
+
* Allowed attribute value types for DOM elements.
|
|
23
21
|
*/
|
|
24
22
|
type DOMNodeAttribute = boolean | string | number | Record<string, unknown> | Array<unknown>;
|
|
25
23
|
type TextName = '#text';
|
|
26
24
|
/**
|
|
27
|
-
*
|
|
28
|
-
* Created by the renderer whenever a JSX expression produces a plain string child.
|
|
25
|
+
* Leaf DOM node containing raw text.
|
|
29
26
|
*/
|
|
30
27
|
type TextNode = {
|
|
31
28
|
nodeName: TextName;
|
|
32
29
|
nodeValue: string;
|
|
33
30
|
} & Node;
|
|
34
31
|
/**
|
|
35
|
-
*
|
|
36
|
-
* Resolves to {@link TextNode} when `nodeName` is `'#text'`, or {@link DOMElement} for
|
|
37
|
-
* any named Kubb element.
|
|
32
|
+
* Virtual DOM node — either a text node or a named element.
|
|
38
33
|
*/
|
|
39
34
|
type DOMNode<T = {
|
|
40
35
|
nodeName: NodeNames;
|
|
@@ -43,8 +38,8 @@ type DOMNode<T = {
|
|
|
43
38
|
} ? U extends '#text' ? TextNode : DOMElement : never;
|
|
44
39
|
type OutputTransformer = (s: string, index: number) => string;
|
|
45
40
|
/**
|
|
46
|
-
*
|
|
47
|
-
*
|
|
41
|
+
* Named element in the Kubb virtual DOM tree.
|
|
42
|
+
* Stores attributes, child nodes, and lifecycle callbacks for rendering.
|
|
48
43
|
*/
|
|
49
44
|
type DOMElement = {
|
|
50
45
|
nodeName: ElementNames;
|
|
@@ -65,32 +60,30 @@ type DOMElement = {
|
|
|
65
60
|
} & Node;
|
|
66
61
|
type NodeNames = ElementNames | TextName;
|
|
67
62
|
/**
|
|
68
|
-
* React node type
|
|
69
|
-
* Alias for React's `ReactNode`.
|
|
63
|
+
* React node type for Kubb JSX components.
|
|
70
64
|
*/
|
|
71
65
|
type KubbReactNode = ReactNode;
|
|
72
66
|
/**
|
|
73
67
|
* React element type returned by Kubb JSX components.
|
|
74
|
-
* Alias for `JSX.Element`.
|
|
75
68
|
*/
|
|
76
69
|
type KubbReactElement = JSX.Element;
|
|
77
70
|
/**
|
|
78
|
-
* Props for the `<kubb-jsx>`
|
|
79
|
-
* Embeds a raw JSX string verbatim in
|
|
71
|
+
* Props for the `<kubb-jsx>` element.
|
|
72
|
+
* Embeds a raw JSX string verbatim in generated output.
|
|
80
73
|
*/
|
|
81
74
|
type KubbJsxProps = {
|
|
82
75
|
children?: string;
|
|
83
76
|
};
|
|
84
77
|
/**
|
|
85
|
-
* Props for the `<kubb-text>`
|
|
86
|
-
* Wraps
|
|
78
|
+
* Props for the `<kubb-text>` element.
|
|
79
|
+
* Wraps React children as plain text in the output.
|
|
87
80
|
*/
|
|
88
81
|
type KubbTextProps = {
|
|
89
82
|
children?: KubbReactNode;
|
|
90
83
|
};
|
|
91
84
|
/**
|
|
92
|
-
* Props for the `<kubb-file>`
|
|
93
|
-
* Represents a generated file
|
|
85
|
+
* Props for the `<kubb-file>` element.
|
|
86
|
+
* Represents a generated file.
|
|
94
87
|
*/
|
|
95
88
|
type KubbFileProps = {
|
|
96
89
|
id?: string;
|
|
@@ -101,58 +94,57 @@ type KubbFileProps = {
|
|
|
101
94
|
meta?: FileNode['meta'];
|
|
102
95
|
};
|
|
103
96
|
/**
|
|
104
|
-
* Props for the `<kubb-source>`
|
|
105
|
-
* Marks a block of source text associated with
|
|
97
|
+
* Props for the `<kubb-source>` element.
|
|
98
|
+
* Marks a block of source text associated with a file.
|
|
106
99
|
*/
|
|
107
100
|
type KubbSourceProps = Omit<SourceNode, 'kind'> & {
|
|
108
101
|
children?: KubbReactNode;
|
|
109
102
|
};
|
|
110
103
|
/**
|
|
111
|
-
* Props for the `<kubb-import>`
|
|
112
|
-
* Declares an import
|
|
104
|
+
* Props for the `<kubb-import>` element.
|
|
105
|
+
* Declares an import statement in the generated file.
|
|
113
106
|
*/
|
|
114
107
|
type KubbImportProps = Omit<ImportNode, 'kind'> & {};
|
|
115
108
|
/**
|
|
116
|
-
* Props for the `<kubb-export>`
|
|
117
|
-
* Declares an export
|
|
109
|
+
* Props for the `<kubb-export>` element.
|
|
110
|
+
* Declares an export statement in the generated file.
|
|
118
111
|
*/
|
|
119
112
|
type KubbExportProps = Omit<ExportNode, 'kind'> & {};
|
|
120
113
|
/**
|
|
121
|
-
* Props for the `<kubb-function>`
|
|
122
|
-
*
|
|
114
|
+
* Props for the `<kubb-function>` element.
|
|
115
|
+
* Generates a function declaration.
|
|
123
116
|
*/
|
|
124
117
|
type KubbFunctionProps = Omit<FunctionNode, 'kind'> & {
|
|
125
118
|
children?: KubbReactNode;
|
|
126
119
|
};
|
|
127
120
|
/**
|
|
128
|
-
* Props for the `<kubb-arrow-function>`
|
|
129
|
-
*
|
|
121
|
+
* Props for the `<kubb-arrow-function>` element.
|
|
122
|
+
* Generates an arrow function declaration.
|
|
130
123
|
*/
|
|
131
124
|
type KubbArrowFunctionProps = Omit<ArrowFunctionNode, 'kind'> & {
|
|
132
125
|
children?: KubbReactNode;
|
|
133
126
|
};
|
|
134
127
|
/**
|
|
135
|
-
* Props for the `<kubb-const>`
|
|
136
|
-
*
|
|
128
|
+
* Props for the `<kubb-const>` element.
|
|
129
|
+
* Generates a constant declaration.
|
|
137
130
|
*/
|
|
138
131
|
type KubbConstProps = Omit<ConstNode, 'kind'> & {
|
|
139
132
|
children?: KubbReactNode;
|
|
140
133
|
};
|
|
141
134
|
/**
|
|
142
|
-
* Props for the `<kubb-type>`
|
|
143
|
-
*
|
|
135
|
+
* Props for the `<kubb-type>` element.
|
|
136
|
+
* Generates a TypeScript type alias declaration.
|
|
144
137
|
*/
|
|
145
138
|
type KubbTypeProps = Omit<TypeNode, 'kind'> & {
|
|
146
139
|
children?: KubbReactNode;
|
|
147
140
|
};
|
|
148
141
|
/**
|
|
149
|
-
* Props
|
|
142
|
+
* Props for the HTML `<br>` element.
|
|
150
143
|
*/
|
|
151
144
|
type LineBreakProps = React.DetailedHTMLProps<React.HTMLAttributes<HTMLBRElement>, HTMLBRElement>;
|
|
152
145
|
/**
|
|
153
|
-
* JSDoc block to attach to a generated declaration.
|
|
154
|
-
*
|
|
155
|
-
* Each string in `comments` becomes one line inside the emitted `/** … *\/` block.
|
|
146
|
+
* JSDoc comment block to attach to a generated declaration.
|
|
147
|
+
* Each string in `comments` becomes one line inside the `/** … *\/` block.
|
|
156
148
|
*
|
|
157
149
|
* @example
|
|
158
150
|
* ```ts
|
|
@@ -173,4 +165,4 @@ type JSDoc = {
|
|
|
173
165
|
};
|
|
174
166
|
//#endregion
|
|
175
167
|
export { KubbTextProps as _, JSDoc as a, TextNode as b, KubbConstProps as c, KubbFunctionProps as d, KubbImportProps as f, KubbSourceProps as g, KubbReactNode as h, ElementNames as i, KubbExportProps as l, KubbReactElement as m, DOMNode as n, Key as o, KubbJsxProps as p, DOMNodeAttribute as r, KubbArrowFunctionProps as s, DOMElement as t, KubbFileProps as u, KubbTypeProps as v, LineBreakProps as y };
|
|
176
|
-
//# sourceMappingURL=types-
|
|
168
|
+
//# sourceMappingURL=types-nAFMiWFw.d.ts.map
|
package/dist/types.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { _ as KubbTextProps, a as JSDoc, b as TextNode, c as KubbConstProps, d as KubbFunctionProps, f as KubbImportProps, g as KubbSourceProps, h as KubbReactNode, i as ElementNames, l as KubbExportProps, m as KubbReactElement, n as DOMNode, o as Key, p as KubbJsxProps, r as DOMNodeAttribute, s as KubbArrowFunctionProps, t as DOMElement, u as KubbFileProps, v as KubbTypeProps, y as LineBreakProps } from "./types-
|
|
1
|
+
import { _ as KubbTextProps, a as JSDoc, b as TextNode, c as KubbConstProps, d as KubbFunctionProps, f as KubbImportProps, g as KubbSourceProps, h as KubbReactNode, i as ElementNames, l as KubbExportProps, m as KubbReactElement, n as DOMNode, o as Key, p as KubbJsxProps, r as DOMNodeAttribute, s as KubbArrowFunctionProps, t as DOMElement, u as KubbFileProps, v as KubbTypeProps, y as LineBreakProps } from "./types-nAFMiWFw.js";
|
|
2
2
|
export { DOMElement, DOMNode, DOMNodeAttribute, ElementNames, JSDoc, Key, KubbArrowFunctionProps, KubbConstProps, KubbExportProps, KubbFileProps, KubbFunctionProps, KubbImportProps, KubbJsxProps, KubbReactElement, KubbReactNode, KubbSourceProps, KubbTextProps, KubbTypeProps, LineBreakProps, TextNode };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kubb/renderer-jsx",
|
|
3
|
-
"version": "5.0.0-
|
|
3
|
+
"version": "5.0.0-beta.75",
|
|
4
4
|
"description": "React integration for Kubb - JSX runtime and component-based code generation with React reconciler for building type-safe generators",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"code-generator",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"registry": "https://registry.npmjs.org/"
|
|
82
82
|
},
|
|
83
83
|
"dependencies": {
|
|
84
|
-
"@kubb/ast": "5.0.0-
|
|
84
|
+
"@kubb/ast": "5.0.0-beta.75"
|
|
85
85
|
},
|
|
86
86
|
"devDependencies": {
|
|
87
87
|
"@types/react": "^19.2.14",
|
package/src/types.ts
CHANGED
|
@@ -3,14 +3,13 @@ import type React from 'react'
|
|
|
3
3
|
import type { JSX, ReactNode } from 'react'
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* React
|
|
7
|
-
* Used to uniquely identify elements in lists and conditional renders.
|
|
6
|
+
* Unique identifier for a React element in lists or conditional renders.
|
|
8
7
|
*/
|
|
9
8
|
export type Key = string | number | bigint
|
|
10
9
|
|
|
11
10
|
/**
|
|
12
|
-
*
|
|
13
|
-
* Each name maps to a corresponding AST node type
|
|
11
|
+
* Custom element names recognized by the Kubb JSX renderer.
|
|
12
|
+
* Each name maps to a corresponding AST node type in the generated code.
|
|
14
13
|
*/
|
|
15
14
|
export type ElementNames =
|
|
16
15
|
| 'br'
|
|
@@ -36,16 +35,14 @@ type Node = {
|
|
|
36
35
|
}
|
|
37
36
|
|
|
38
37
|
/**
|
|
39
|
-
* Allowed attribute value types
|
|
40
|
-
* Corresponds to the range of prop values JSX components may pass to intrinsic elements.
|
|
38
|
+
* Allowed attribute value types for DOM elements.
|
|
41
39
|
*/
|
|
42
40
|
export type DOMNodeAttribute = boolean | string | number | Record<string, unknown> | Array<unknown>
|
|
43
41
|
|
|
44
42
|
type TextName = '#text'
|
|
45
43
|
|
|
46
44
|
/**
|
|
47
|
-
*
|
|
48
|
-
* Created by the renderer whenever a JSX expression produces a plain string child.
|
|
45
|
+
* Leaf DOM node containing raw text.
|
|
49
46
|
*/
|
|
50
47
|
export type TextNode = {
|
|
51
48
|
nodeName: TextName
|
|
@@ -53,9 +50,7 @@ export type TextNode = {
|
|
|
53
50
|
} & Node
|
|
54
51
|
|
|
55
52
|
/**
|
|
56
|
-
*
|
|
57
|
-
* Resolves to {@link TextNode} when `nodeName` is `'#text'`, or {@link DOMElement} for
|
|
58
|
-
* any named Kubb element.
|
|
53
|
+
* Virtual DOM node — either a text node or a named element.
|
|
59
54
|
*/
|
|
60
55
|
export type DOMNode<T = { nodeName: NodeNames }> = T extends {
|
|
61
56
|
nodeName: infer U
|
|
@@ -68,8 +63,8 @@ export type DOMNode<T = { nodeName: NodeNames }> = T extends {
|
|
|
68
63
|
type OutputTransformer = (s: string, index: number) => string
|
|
69
64
|
|
|
70
65
|
/**
|
|
71
|
-
*
|
|
72
|
-
*
|
|
66
|
+
* Named element in the Kubb virtual DOM tree.
|
|
67
|
+
* Stores attributes, child nodes, and lifecycle callbacks for rendering.
|
|
73
68
|
*/
|
|
74
69
|
export type DOMElement = {
|
|
75
70
|
nodeName: ElementNames
|
|
@@ -94,36 +89,34 @@ export type DOMElement = {
|
|
|
94
89
|
type NodeNames = ElementNames | TextName
|
|
95
90
|
|
|
96
91
|
/**
|
|
97
|
-
* React node type
|
|
98
|
-
* Alias for React's `ReactNode`.
|
|
92
|
+
* React node type for Kubb JSX components.
|
|
99
93
|
*/
|
|
100
94
|
export type KubbReactNode = ReactNode
|
|
101
95
|
|
|
102
96
|
/**
|
|
103
97
|
* React element type returned by Kubb JSX components.
|
|
104
|
-
* Alias for `JSX.Element`.
|
|
105
98
|
*/
|
|
106
99
|
export type KubbReactElement = JSX.Element
|
|
107
100
|
|
|
108
101
|
/**
|
|
109
|
-
* Props for the `<kubb-jsx>`
|
|
110
|
-
* Embeds a raw JSX string verbatim in
|
|
102
|
+
* Props for the `<kubb-jsx>` element.
|
|
103
|
+
* Embeds a raw JSX string verbatim in generated output.
|
|
111
104
|
*/
|
|
112
105
|
export type KubbJsxProps = {
|
|
113
106
|
children?: string
|
|
114
107
|
}
|
|
115
108
|
|
|
116
109
|
/**
|
|
117
|
-
* Props for the `<kubb-text>`
|
|
118
|
-
* Wraps
|
|
110
|
+
* Props for the `<kubb-text>` element.
|
|
111
|
+
* Wraps React children as plain text in the output.
|
|
119
112
|
*/
|
|
120
113
|
export type KubbTextProps = {
|
|
121
114
|
children?: KubbReactNode
|
|
122
115
|
}
|
|
123
116
|
|
|
124
117
|
/**
|
|
125
|
-
* Props for the `<kubb-file>`
|
|
126
|
-
* Represents a generated file
|
|
118
|
+
* Props for the `<kubb-file>` element.
|
|
119
|
+
* Represents a generated file.
|
|
127
120
|
*/
|
|
128
121
|
export type KubbFileProps = {
|
|
129
122
|
id?: string
|
|
@@ -135,66 +128,65 @@ export type KubbFileProps = {
|
|
|
135
128
|
}
|
|
136
129
|
|
|
137
130
|
/**
|
|
138
|
-
* Props for the `<kubb-source>`
|
|
139
|
-
* Marks a block of source text associated with
|
|
131
|
+
* Props for the `<kubb-source>` element.
|
|
132
|
+
* Marks a block of source text associated with a file.
|
|
140
133
|
*/
|
|
141
134
|
export type KubbSourceProps = Omit<SourceNode, 'kind'> & {
|
|
142
135
|
children?: KubbReactNode
|
|
143
136
|
}
|
|
144
137
|
|
|
145
138
|
/**
|
|
146
|
-
* Props for the `<kubb-import>`
|
|
147
|
-
* Declares an import
|
|
139
|
+
* Props for the `<kubb-import>` element.
|
|
140
|
+
* Declares an import statement in the generated file.
|
|
148
141
|
*/
|
|
149
142
|
export type KubbImportProps = Omit<ImportNode, 'kind'> & {}
|
|
150
143
|
|
|
151
144
|
/**
|
|
152
|
-
* Props for the `<kubb-export>`
|
|
153
|
-
* Declares an export
|
|
145
|
+
* Props for the `<kubb-export>` element.
|
|
146
|
+
* Declares an export statement in the generated file.
|
|
154
147
|
*/
|
|
155
148
|
export type KubbExportProps = Omit<ExportNode, 'kind'> & {}
|
|
156
149
|
|
|
157
150
|
/**
|
|
158
|
-
* Props for the `<kubb-function>`
|
|
159
|
-
*
|
|
151
|
+
* Props for the `<kubb-function>` element.
|
|
152
|
+
* Generates a function declaration.
|
|
160
153
|
*/
|
|
161
154
|
export type KubbFunctionProps = Omit<FunctionNode, 'kind'> & {
|
|
162
155
|
children?: KubbReactNode
|
|
163
156
|
}
|
|
164
157
|
|
|
165
158
|
/**
|
|
166
|
-
* Props for the `<kubb-arrow-function>`
|
|
167
|
-
*
|
|
159
|
+
* Props for the `<kubb-arrow-function>` element.
|
|
160
|
+
* Generates an arrow function declaration.
|
|
168
161
|
*/
|
|
169
162
|
export type KubbArrowFunctionProps = Omit<ArrowFunctionNode, 'kind'> & {
|
|
170
163
|
children?: KubbReactNode
|
|
171
164
|
}
|
|
172
165
|
|
|
173
166
|
/**
|
|
174
|
-
* Props for the `<kubb-const>`
|
|
175
|
-
*
|
|
167
|
+
* Props for the `<kubb-const>` element.
|
|
168
|
+
* Generates a constant declaration.
|
|
176
169
|
*/
|
|
177
170
|
export type KubbConstProps = Omit<ConstNode, 'kind'> & {
|
|
178
171
|
children?: KubbReactNode
|
|
179
172
|
}
|
|
180
173
|
|
|
181
174
|
/**
|
|
182
|
-
* Props for the `<kubb-type>`
|
|
183
|
-
*
|
|
175
|
+
* Props for the `<kubb-type>` element.
|
|
176
|
+
* Generates a TypeScript type alias declaration.
|
|
184
177
|
*/
|
|
185
178
|
export type KubbTypeProps = Omit<TypeNode, 'kind'> & {
|
|
186
179
|
children?: KubbReactNode
|
|
187
180
|
}
|
|
188
181
|
|
|
189
182
|
/**
|
|
190
|
-
* Props
|
|
183
|
+
* Props for the HTML `<br>` element.
|
|
191
184
|
*/
|
|
192
185
|
export type LineBreakProps = React.DetailedHTMLProps<React.HTMLAttributes<HTMLBRElement>, HTMLBRElement>
|
|
193
186
|
|
|
194
187
|
/**
|
|
195
|
-
* JSDoc block to attach to a generated declaration.
|
|
196
|
-
*
|
|
197
|
-
* Each string in `comments` becomes one line inside the emitted `/** … *\/` block.
|
|
188
|
+
* JSDoc comment block to attach to a generated declaration.
|
|
189
|
+
* Each string in `comments` becomes one line inside the `/** … *\/` block.
|
|
198
190
|
*
|
|
199
191
|
* @example
|
|
200
192
|
* ```ts
|