Skip to content

Commit b5c8b4a

Browse files
committed
literal type proposal
1 parent 53f9a1a commit b5c8b4a

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
package org.scalajs.dom
2+
3+
/** Short aliases of all the dom.HTMLThing classes */
4+
object HTMLLiterals {
5+
def createElement(tagName: "a"): HTMLAnchorElement = js.native
6+
def createElement(tagName: "audio"): HTMLAudioElement = js.native
7+
def createElement(tagName: "area"): HTMLAreaElement = js.native
8+
def createElement(tagName: "base"): HTMLBaseElement = js.native
9+
def createElement(tagName: "body"): HTMLBodyElement = js.native
10+
def createElement(tagName: "button"): HTMLButtonElement = js.native
11+
def createElement(tagName: "br"): HTMLBRElement = js.native
12+
def createElement(tagName: "canvas"): HTMLCanvasElement = js.native
13+
def createElement(tagName: "datalist"): HTMLDataListElement = js.native
14+
def createElement(tagName: "div"): HTMLDivElement = js.native
15+
def createElement(tagName: "dialog"): HTMLDialogElement = js.native
16+
def createElement(tagName: "dl"): HTMLDListElement = js.native
17+
def createElement(tagName: "embed"): HTMLEmbedElement = js.native
18+
def createElement(tagName: "fieldset"): HTMLFieldSetElement = js.native
19+
def createElement(tagName: "form"): HTMLFormElement = js.native
20+
def createElement(tagName: "head"): HTMLHeadElement = js.native
21+
def createElement(tagName: "h1"): HTMLHeadingElement = js.native
22+
def createElement(tagName: "html"): HTMLHtmlElement = js.native
23+
def createElement(tagName: "hr"): HTMLHRElement = js.native
24+
def createElement(tagName: "iframe"): HTMLIFrameElement = js.native
25+
def createElement(tagName: "img"): HTMLImageElement = js.native
26+
def createElement(tagName: "input"): HTMLInputElement = js.native
27+
def createElement(tagName: "label"): HTMLLabelElement = js.native
28+
def createElement(tagName: "legend"): HTMLLegendElement = js.native
29+
def createElement(tagName: "li"): HTMLLIElement = js.native
30+
def createElement(tagName: "link"): HTMLLinkElement = js.native
31+
def createElement(tagName: "map"): HTMLMapElement = js.native
32+
def createElement(tagName: "menu"): HTMLMenuElement = js.native
33+
def createElement(tagName: "meta"): HTMLMetaElement = js.native
34+
def createElement(tagName: "mod"): HTMLModElement = js.native
35+
def createElement(tagName: "object"): HTMLObjectElement = js.native
36+
def createElement(tagName: "ol"): HTMLOListElement = js.native
37+
def createElement(tagName: "optgroup"): HTMLOptGroupElement = js.native
38+
def createElement(tagName: "option"): HTMLOptionElement = js.native
39+
def createElement(tagName: "p"): HTMLParagraphElement = js.native
40+
def createElement(tagName: "param"): HTMLParamElement = js.native
41+
def createElement(tagName: "pre"): HTMLPreElement = js.native
42+
def createElement(tagName: "progress"): HTMLProgressElement = js.native
43+
def createElement(tagName: "blockquote"): HTMLQuoteElement = js.native
44+
def createElement(tagName: "script"): HTMLScriptElement = js.native
45+
def createElement(tagName: "select"): HTMLSelectElement = js.native
46+
def createElement(tagName: "source"): HTMLSourceElement = js.native
47+
def createElement(tagName: "span"): HTMLSpanElement = js.native
48+
def createElement(tagName: "style"): HTMLStyleElement = js.native
49+
def createElement(tagName: "table"): HTMLTableElement = js.native
50+
def createElement(tagName: "caption"): HTMLTableCaptionElement = js.native
51+
def createElement(tagName: "td"): HTMLTableCellElement = js.native
52+
def createElement(tagName: "col"): HTMLTableColElement = js.native
53+
def createElement(tagName: "tr"): HTMLTableRowElement = js.native
54+
def createElement(tagName: "tbody"): HTMLTableSectionElement = js.native
55+
def createElement(tagName: "title"): HTMLTitleElement = js.native
56+
def createElement(tagName: "textarea"): HTMLTextAreaElement = js.native
57+
def createElement(tagName: "track"): HTMLTrackElement = js.native
58+
def createElement(tagName: "ul"): HTMLUListElement = js.native
59+
def createElement(tagName: "unknown"): HTMLUnknownElement = js.native
60+
def createElement(tagName: "video"): HTMLVideoElement = js.native
61+
}

0 commit comments

Comments
 (0)