Skip to content

htmy.html

DOCTYPE

Document type declaration.

Source code in htmy/html.py
class DOCTYPE:
    """Document type declaration."""

    html = SafeStr("<!DOCTYPE html>")
    """HTML document type."""

html = SafeStr('<!DOCTYPE html>') class-attribute instance-attribute

HTML document type.

a

Bases: Tag

<a> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a.

Source code in htmy/html.py
class a(Tag):
    """
    `<a>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

abbr

Bases: Tag

<abbr> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/abbr.

Source code in htmy/html.py
class abbr(Tag):
    """
    `<abbr>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/abbr.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

address

Bases: Tag

<address> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/address.

Source code in htmy/html.py
class address(Tag):
    """
    `<address>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/address.
    """

    __slots__ = ()

area

Bases: StandaloneTag

<area> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/area.

Source code in htmy/html.py
class area(StandaloneTag):
    """
    `<area>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/area.
    """

    __slots__ = ()

article

Bases: Tag

<article> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/article.

Source code in htmy/html.py
class article(Tag):
    """
    `<article>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/article.
    """

    __slots__ = ()

aside

Bases: Tag

<aside> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside.

Source code in htmy/html.py
class aside(Tag):
    """
    `<aside>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside.
    """

    __slots__ = ()

audio

Bases: Tag

<audio> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/audio.

Source code in htmy/html.py
class audio(Tag):
    """
    `<audio>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/audio.
    """

    __slots__ = ()

b

Bases: Tag

<b> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/b.

Source code in htmy/html.py
class b(Tag):
    """
    `<b>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/b.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

base

Bases: StandaloneTag

<base> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base.

Source code in htmy/html.py
class base(StandaloneTag):
    """
    `<base>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base.
    """

    __slots__ = ()

bdi

Bases: Tag

<bdi> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdi.

Source code in htmy/html.py
class bdi(Tag):
    """
    `<bdi>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdi.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

bdo

Bases: Tag

<bdo> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdo.

Source code in htmy/html.py
class bdo(Tag):
    """
    `<bdo>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdo.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

blockquote

Bases: Tag

<blockquote> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/blockquote.

Source code in htmy/html.py
class blockquote(Tag):
    """
    `<blockquote>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/blockquote.
    """

    __slots__ = ()

body

Bases: Tag

<body> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/body.

Source code in htmy/html.py
class body(Tag):
    """
    `<body>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/body.
    """

    __slots__ = ()

br

Bases: StandaloneTag

<br> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/br.

Source code in htmy/html.py
class br(StandaloneTag):
    """
    `<br>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/br.
    """

    __slots__ = ()

button

Bases: Tag

<button> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button.

Source code in htmy/html.py
class button(Tag):
    """
    `<button>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button.
    """

    __slots__ = ()

canvas

Bases: Tag

<canvas> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas.

Source code in htmy/html.py
class canvas(Tag):
    """
    `<canvas>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/canvas.
    """

    __slots__ = ()

caption

Bases: Tag

<caption> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/caption.

Source code in htmy/html.py
class caption(Tag):
    """
    `<caption>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/caption.
    """

    __slots__ = ()

cite

Bases: Tag

<cite> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/cite.

Source code in htmy/html.py
class cite(Tag):
    """
    `<cite>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/cite.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

code

Bases: Tag

<code> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/code.

Source code in htmy/html.py
class code(Tag):
    """
    `<code>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/code.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

col

Bases: StandaloneTag

<col> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/col.

Source code in htmy/html.py
class col(StandaloneTag):
    """
    `<col>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/col.
    """

    __slots__ = ()

colgroup

Bases: StandaloneTag

<colgroup> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/colgroup.

Source code in htmy/html.py
class colgroup(StandaloneTag):
    """
    `<colgroup>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/colgroup.
    """

    __slots__ = ()

data

Bases: Tag

<data> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/data.

Source code in htmy/html.py
class data(Tag):
    """
    `<data>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/data.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

datalist

Bases: Tag

<datalist> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/datalist.

Source code in htmy/html.py
class datalist(Tag):
    """
    `<datalist>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/datalist.
    """

    __slots__ = ()

dd

Bases: Tag

<dd> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dd.

Source code in htmy/html.py
class dd(Tag):
    """
    `<dd>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dd.
    """

    __slots__ = ()

del_

Bases: Tag

<del> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/del.

Source code in htmy/html.py
class del_(Tag):
    """
    `<del>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/del.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

    @property
    def _htmy_name(self) -> str:
        return "del"

details

Bases: Tag

<details> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details.

Source code in htmy/html.py
class details(Tag):
    """
    `<details>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details.
    """

    __slots__ = ()

dfn

Bases: Tag

<dfn> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dfn.

Source code in htmy/html.py
class dfn(Tag):
    """
    `<dfn>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dfn.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

dialog

Bases: Tag

<dialog> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dialog.

Source code in htmy/html.py
class dialog(Tag):
    """
    `<dialog>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dialog.
    """

    __slots__ = ()

div

Bases: Tag

<div> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/div.

Source code in htmy/html.py
class div(Tag):
    """
    `<div>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/div.
    """

    __slots__ = ()

dl

Bases: Tag

<dl> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dl.

Source code in htmy/html.py
class dl(Tag):
    """
    `<dl>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dl.
    """

    __slots__ = ()

dt

Bases: Tag

<dt> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dt.

Source code in htmy/html.py
class dt(Tag):
    """
    `<dt>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/dt.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

em

Bases: Tag

<em> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/em.

Source code in htmy/html.py
class em(Tag):
    """
    `<em>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/em.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

embed

Bases: StandaloneTag

<embed> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/embed.

Source code in htmy/html.py
class embed(StandaloneTag):
    """
    `<embed>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/embed.
    """

    __slots__ = ()

fieldset

Bases: Tag

<fieldset> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/fieldset.

Source code in htmy/html.py
class fieldset(Tag):
    """
    `<fieldset>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/fieldset.
    """

    __slots__ = ()

figcaption

Bases: Tag

<figcaption> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figcaption.

Source code in htmy/html.py
class figcaption(Tag):
    """
    `<figcaption>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figcaption.
    """

    __slots__ = ()

figure

Bases: Tag

<figure> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figure.

Source code in htmy/html.py
class figure(Tag):
    """
    `<figure>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figure.
    """

    __slots__ = ()

footer

Bases: Tag

<footer> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/footer.

Source code in htmy/html.py
class footer(Tag):
    """
    `<footer>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/footer.
    """

    __slots__ = ()

form

Bases: Tag

<form> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/form.

Source code in htmy/html.py
class form(Tag):
    """
    `<form>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/form.
    """

    __slots__ = ()

h1

Bases: Tag

<h1> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h1.

Source code in htmy/html.py
class h1(Tag):
    """
    `<h1>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h1.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

h2

Bases: Tag

<h2> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h2.

Source code in htmy/html.py
class h2(Tag):
    """
    `<h2>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h2.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

h3

Bases: Tag

<h3> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h3.

Source code in htmy/html.py
class h3(Tag):
    """
    `<h3>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h3.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

h4

Bases: Tag

<h4> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h4.

Source code in htmy/html.py
class h4(Tag):
    """
    `<h4>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h4.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

h5

Bases: Tag

<h5> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h5.

Source code in htmy/html.py
class h5(Tag):
    """
    `<h5>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h5.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

h6

Bases: Tag

<h6> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h6.

Source code in htmy/html.py
class h6(Tag):
    """
    `<h6>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/h6.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

head

Bases: Tag

<head> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/head.

Source code in htmy/html.py
class head(Tag):
    """
    `<head>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/head.
    """

    __slots__ = ()

header

Bases: Tag

<header> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/header.

Source code in htmy/html.py
class header(Tag):
    """
    `<header>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/header.
    """

    __slots__ = ()

hgroup

Bases: Tag

<hgroup> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hgroup.

Source code in htmy/html.py
class hgroup(Tag):
    """
    `<hgroup>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hgroup.
    """

    __slots__ = ()

hr

Bases: StandaloneTag

<hr> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hr.

Source code in htmy/html.py
class hr(StandaloneTag):
    """
    `<hr>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hr.
    """

    __slots__ = ()

html

Bases: Tag

<html> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/html.

Source code in htmy/html.py
class html(Tag):
    """
    `<html>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/html.
    """

    __slots__ = ()

i

Bases: Tag

<i> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/i.

Source code in htmy/html.py
class i(Tag):
    """
    `<i>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/i.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

iframe

Bases: TagWithProps

<iframe> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe.

Source code in htmy/html.py
class iframe(TagWithProps):
    """
    `<iframe>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe.
    """

    __slots__ = ()

img

Bases: StandaloneTag

<img> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img.

Source code in htmy/html.py
class img(StandaloneTag):
    """
    `<img>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img.
    """

    __slots__ = ()

input_

Bases: StandaloneTag

<input> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input.

Source code in htmy/html.py
class input_(StandaloneTag):
    """
    `<input>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input.
    """

    __slots__ = ()

    @property
    def _htmy_name(self) -> str:
        return "input"

ins

Bases: Tag

<ins> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ins.

Source code in htmy/html.py
class ins(Tag):
    """
    `<ins>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ins.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

label

Bases: Tag

<label> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/label.

Source code in htmy/html.py
class label(Tag):
    """
    `<label>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/label.
    """

    __slots__ = ()

legend

Bases: Tag

<legend> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/legend.

Source code in htmy/html.py
class legend(Tag):
    """
    `<legend>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/legend.
    """

    __slots__ = ()

li

Bases: Tag

<li> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/li.

Source code in htmy/html.py
class li(Tag):
    """
    `<li>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/li.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

Bases: StandaloneTag

<link> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link.

Source code in htmy/html.py
class link(StandaloneTag):
    """
    `<link>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link.
    """

    __slots__ = ()

    @classmethod
    def css(cls, href: str) -> link:
        return cls(rel="stylesheet", type="text/css", href=href)

main

Bases: Tag

<main> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/main.

Source code in htmy/html.py
class main(Tag):
    """
    `<main>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/main.
    """

    __slots__ = ()

map

Bases: Tag

<map> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/map.

Source code in htmy/html.py
class map(Tag):
    """
    `<map>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/map.
    """

    __slots__ = ()

mark

Bases: Tag

<mark> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/mark.

Source code in htmy/html.py
class mark(Tag):
    """
    `<mark>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/mark.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

menu

Bases: Tag

<menu> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/menu.

Source code in htmy/html.py
class menu(Tag):
    """
    `<menu>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/menu.
    """

    __slots__ = ()

meta

Bases: StandaloneTag

<meta> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta.

Source code in htmy/html.py
class meta(StandaloneTag):
    """
    `<meta>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta.
    """

    __slots__ = ()

    @classmethod
    def author(cls, content: str) -> meta:
        return cls(name="author", content=content)

    @classmethod
    def charset(cls, charset: str = "utf-8") -> meta:
        return cls(charset=charset)

    @classmethod
    def description(cls, content: str) -> meta:
        return cls(name="description", content=content)

    @classmethod
    def keywords(cls, content: str) -> meta:
        return cls(name="keywords", content=content)

    @classmethod
    def viewport(cls, content: str = "width=device-width, initial-scale=1.0") -> meta:
        return cls(name="viewport", content=content)

meter

Bases: Tag

<meter> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meter.

Source code in htmy/html.py
class meter(Tag):
    """
    `<meter>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meter.
    """

    __slots__ = ()

nav

Bases: Tag

<nav> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/nav.

Source code in htmy/html.py
class nav(Tag):
    """
    `<nav>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/nav.
    """

    __slots__ = ()

noscript

Bases: Tag

<noscript> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/noscript.

Source code in htmy/html.py
class noscript(Tag):
    """
    `<noscript>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/noscript.
    """

    __slots__ = ()

object

Bases: Tag

<object> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/object.

Source code in htmy/html.py
class object(Tag):
    """
    `<object>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/object.
    """

    __slots__ = ()

ol

Bases: Tag

<ol> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol.

Source code in htmy/html.py
class ol(Tag):
    """
    `<ol>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol.
    """

    __slots__ = ()

optgroup

Bases: Tag

<optgroup> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/optgroup.

Source code in htmy/html.py
class optgroup(Tag):
    """
    `<optgroup>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/optgroup.
    """

    __slots__ = ()

option

Bases: Tag

<option> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/option.

Source code in htmy/html.py
class option(Tag):
    """
    `<option>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/option.
    """

    __slots__ = ()

output

Bases: Tag

<output> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/output.

Source code in htmy/html.py
class output(Tag):
    """
    `<output>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/output.
    """

    __slots__ = ()

p

Bases: Tag

<p> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/p.

Source code in htmy/html.py
class p(Tag):
    """
    `<p>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/p.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

picture

Bases: Tag

<picture> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/picture.

Source code in htmy/html.py
class picture(Tag):
    """
    `<picture>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/picture.
    """

    __slots__ = ()

pre

Bases: Tag

<pre> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/pre.

Source code in htmy/html.py
class pre(Tag):
    """
    `<pre>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/pre.
    """

    __slots__ = ()

progress

Bases: Tag

<progress> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress.

Source code in htmy/html.py
class progress(Tag):
    """
    `<progress>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/progress.
    """

    __slots__ = ()

q

Bases: Tag

<q> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/q.

Source code in htmy/html.py
class q(Tag):
    """
    `<q>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/q.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

s

Bases: Tag

<s> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/s.

Source code in htmy/html.py
class s(Tag):
    """
    `<s>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/s.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

samp

Bases: Tag

<samp> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/samp.

Source code in htmy/html.py
class samp(Tag):
    """
    `<samp>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/samp.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

script

Bases: Tag

<script> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script.

Source code in htmy/html.py
class script(Tag):
    """
    `<script>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script.
    """

    __slots__ = ()

    def __init__(self, text: str = "", **props: PropertyValue) -> None:
        """
        Initialization.

        Arguments:
            text: The inner content of the tag. If not empty, it should be a
                `SafeStr` for HTML and plain `str` for XHTML.
            **props: Tag attributes.
        """
        super().__init__(text, **props)

__init__(text='', **props)

Initialization.

Parameters:

Name Type Description Default
text str

The inner content of the tag. If not empty, it should be a SafeStr for HTML and plain str for XHTML.

''
**props PropertyValue

Tag attributes.

{}
Source code in htmy/html.py
def __init__(self, text: str = "", **props: PropertyValue) -> None:
    """
    Initialization.

    Arguments:
        text: The inner content of the tag. If not empty, it should be a
            `SafeStr` for HTML and plain `str` for XHTML.
        **props: Tag attributes.
    """
    super().__init__(text, **props)

search

Bases: Tag

<search> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/search.

Source code in htmy/html.py
class search(Tag):
    """
    `<search>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/search.
    """

    __slots__ = ()

section

Bases: Tag

<section> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/section.

Source code in htmy/html.py
class section(Tag):
    """
    `<section>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/section.
    """

    __slots__ = ()

select

Bases: Tag

<select> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select.

Source code in htmy/html.py
class select(Tag):
    """
    `<select>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select.
    """

    __slots__ = ()

slot

Bases: Tag

<slot> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/slot.

Source code in htmy/html.py
class slot(Tag):
    """
    `<slot>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/slot.
    """

    __slots__ = ()

small

Bases: Tag

<small> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/small.

Source code in htmy/html.py
class small(Tag):
    """
    `<small>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/small.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

source

Bases: StandaloneTag

<source> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/source.

Source code in htmy/html.py
class source(StandaloneTag):
    """
    `<source>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/source.
    """

    __slots__ = ()

span

Bases: Tag

<span> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/span.

Source code in htmy/html.py
class span(Tag):
    """
    `<span>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/span.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

strong

Bases: Tag

<strong> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/strong.

Source code in htmy/html.py
class strong(Tag):
    """
    `<strong>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/strong.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

style

Bases: Tag

<style> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/style.

Source code in htmy/html.py
class style(Tag):
    """
    `<style>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/style.
    """

    __slots__ = ()

    def __init__(self, content: str, **props: PropertyValue) -> None:
        """
        Initialization.

        Arguments:
            content: The content of the tag. It is automatically converted to a `SafeStr`.
            **props: Tag attributes.
        """
        super().__init__(SafeStr(content), **props)

__init__(content, **props)

Initialization.

Parameters:

Name Type Description Default
content str

The content of the tag. It is automatically converted to a SafeStr.

required
**props PropertyValue

Tag attributes.

{}
Source code in htmy/html.py
def __init__(self, content: str, **props: PropertyValue) -> None:
    """
    Initialization.

    Arguments:
        content: The content of the tag. It is automatically converted to a `SafeStr`.
        **props: Tag attributes.
    """
    super().__init__(SafeStr(content), **props)

sub

Bases: Tag

<sub> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sub.

Source code in htmy/html.py
class sub(Tag):
    """
    `<sub>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sub.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

summary

Bases: Tag

<summary> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary.

Source code in htmy/html.py
class summary(Tag):
    """
    `<summary>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

sup

Bases: Tag

<sup> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sup.

Source code in htmy/html.py
class sup(Tag):
    """
    `<sup>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sup.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

table

Bases: Tag

<table> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/table.

Source code in htmy/html.py
class table(Tag):
    """
    `<table>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/table.
    """

    __slots__ = ()

tbody

Bases: Tag

<tbody> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tbody.

Source code in htmy/html.py
class tbody(Tag):
    """
    `<tbody>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tbody.
    """

    __slots__ = ()

td

Bases: Tag

<td> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td.

Source code in htmy/html.py
class td(Tag):
    """
    `<td>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

template

Bases: Tag

<> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/template.

Source code in htmy/html.py
class template(Tag):
    """
    `<>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/template.
    """

    __slots__ = ()

textarea

Bases: Tag

<textarea> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea.

Source code in htmy/html.py
class textarea(Tag):
    """
    `<textarea>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/textarea.
    """

    __slots__ = ()

tfoot

Bases: Tag

<tfoot> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tfoot.

Source code in htmy/html.py
class tfoot(Tag):
    """
    `<tfoot>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tfoot.
    """

    __slots__ = ()

th

Bases: Tag

<th> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/th.

Source code in htmy/html.py
class th(Tag):
    """
    `<th>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/th.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

thead

Bases: Tag

<thead> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/thead.

Source code in htmy/html.py
class thead(Tag):
    """
    `<thead>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/thead.
    """

    __slots__ = ()

time

Bases: Tag

<time> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/time.

Source code in htmy/html.py
class time(Tag):
    """
    `<time>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/time.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

title

Bases: Tag

<title> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/title.

Source code in htmy/html.py
class title(Tag):
    """
    `<title>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/title.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

    def __init__(self, text: str, **props: PropertyValue) -> None:
        super().__init__(text, **props)

tr

Bases: Tag

<tr> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tr.

Source code in htmy/html.py
class tr(Tag):
    """
    `<tr>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tr.
    """

    __slots__ = ()

track

Bases: StandaloneTag

<track> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/track.

Source code in htmy/html.py
class track(StandaloneTag):
    """
    `<track>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/track.
    """

    __slots__ = ()

u

Bases: Tag

<u> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/u.

Source code in htmy/html.py
class u(Tag):
    """
    `<u>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/u.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

ul

Bases: Tag

<ul> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ul.

Source code in htmy/html.py
class ul(Tag):
    """
    `<ul>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ul.
    """

    __slots__ = ()

var

Bases: Tag

<var> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/var.

Source code in htmy/html.py
class var(Tag):
    """
    `<var>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/var.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children

video

Bases: Tag

<video> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video.

Source code in htmy/html.py
class video(Tag):
    """
    `<video>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video.
    """

    __slots__ = ()

wbr

Bases: Tag

<> element.

See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/.

Source code in htmy/html.py
class wbr(Tag):
    """
    `<>` element.

    See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/.
    """

    __slots__ = ()

    tag_config = _DefaultTagConfig.inline_children