Skip to content

Commit 3b2e33c

Browse files
committed
move JSX types to tsx namespace
1 parent 9b21576 commit 3b2e33c

File tree

1 file changed

+55
-57
lines changed

1 file changed

+55
-57
lines changed

src/core/vdom.ts

+55-57
Original file line numberDiff line numberDiff line change
@@ -79,63 +79,61 @@ import { auto } from './diff';
7979
import RegistryHandler from './RegistryHandler';
8080
import { NodeHandler } from './NodeHandler';
8181

82-
declare global {
83-
namespace JSX {
84-
type Element = WNode;
85-
interface ElementAttributesProperty {
86-
__properties__: {};
87-
}
88-
interface IntrinsicElements {
89-
svg: SVGAttributes;
90-
a: AnchorAttributes;
91-
audio: AudioAttributes;
92-
base: BaseAttributes;
93-
blockquote: BlockquoteAttributes;
94-
button: ButtonAttributes;
95-
canvas: CanvasAttributes;
96-
col: ColAttributes;
97-
colgroup: ColgroupAttributes;
98-
del: DelAttributes;
99-
details: DetailsAttributes;
100-
dialog: DialogAttributes;
101-
embed: EmbedAttributes;
102-
fieldset: FieldsetAttributes;
103-
form: FormAttributes;
104-
iframe: IFrameAttributes;
105-
img: ImgAttributes;
106-
ins: InsAttributes;
107-
input: InputAttributes;
108-
keygen: KeygenAttributes;
109-
label: LabelAttributes;
110-
link: LinkAttributes;
111-
map: MapAttributes;
112-
menu: MenuAttributes;
113-
meta: MetaAttributes;
114-
meter: MeterAttributes;
115-
object: ObjectAttributes;
116-
ol: OlAttributes;
117-
optgroup: OptgroupAttributes;
118-
option: OptionAttributes;
119-
output: OutputAttributes;
120-
param: ParamAttributes;
121-
progress: ProgressAttributes;
122-
q: QuoteAttributes;
123-
slot: SlotAttributes;
124-
select: SelectAttributes;
125-
source: SourceAttributes;
126-
style: StyleAttributes;
127-
table: TableAttributes;
128-
td: TdAttributes;
129-
textarea: TextareaAttributes;
130-
th: ThAttributes;
131-
time: TimeAttributes;
132-
track: TrackAttributes;
133-
video: VideoAttributes;
134-
[key: string]: VNodeProperties;
135-
}
136-
interface ElementChildrenAttribute {
137-
__children__: {};
138-
}
82+
export namespace tsx.JSX {
83+
export type Element = WNode;
84+
export interface ElementAttributesProperty {
85+
__properties__: {};
86+
}
87+
export interface IntrinsicElements {
88+
svg: SVGAttributes;
89+
a: AnchorAttributes;
90+
audio: AudioAttributes;
91+
base: BaseAttributes;
92+
blockquote: BlockquoteAttributes;
93+
button: ButtonAttributes;
94+
canvas: CanvasAttributes;
95+
col: ColAttributes;
96+
colgroup: ColgroupAttributes;
97+
del: DelAttributes;
98+
details: DetailsAttributes;
99+
dialog: DialogAttributes;
100+
embed: EmbedAttributes;
101+
fieldset: FieldsetAttributes;
102+
form: FormAttributes;
103+
iframe: IFrameAttributes;
104+
img: ImgAttributes;
105+
ins: InsAttributes;
106+
input: InputAttributes;
107+
keygen: KeygenAttributes;
108+
label: LabelAttributes;
109+
link: LinkAttributes;
110+
map: MapAttributes;
111+
menu: MenuAttributes;
112+
meta: MetaAttributes;
113+
meter: MeterAttributes;
114+
object: ObjectAttributes;
115+
ol: OlAttributes;
116+
optgroup: OptgroupAttributes;
117+
option: OptionAttributes;
118+
output: OutputAttributes;
119+
param: ParamAttributes;
120+
progress: ProgressAttributes;
121+
q: QuoteAttributes;
122+
slot: SlotAttributes;
123+
select: SelectAttributes;
124+
source: SourceAttributes;
125+
style: StyleAttributes;
126+
table: TableAttributes;
127+
td: TdAttributes;
128+
textarea: TextareaAttributes;
129+
th: ThAttributes;
130+
time: TimeAttributes;
131+
track: TrackAttributes;
132+
video: VideoAttributes;
133+
[key: string]: VNodeProperties;
134+
}
135+
export interface ElementChildrenAttribute {
136+
__children__: {};
139137
}
140138
}
141139

0 commit comments

Comments
 (0)