enum classafSlim::TagStyle

sys::Obj
  sys::Enum
    afSlim::TagStyle

@Serializable { simple=true }

Defines the ending style rendered tags should have: HTML, XHTML or XML.

fromStr

Source

static new fromStr(Str name, Bool checked := true)

Return the TagStyle instance for the specified name. If not a valid name and checked is false return null, otherwise throw ParseErr.

html

Source

const static TagStyle html := ...

Dictates that all void elements such as meta, br and input are printed without an end tag:

<input type="submit">
<br>

All non void elements are NOT rendered as self closing, even when empty:

<script></script>

HTML documents, when served up from a web server, should have a Content-Type of text/html.

vals

Source

const static TagStyle[] vals := ...

List of TagStyle values indexed by ordinal

xhtml

Source

const static TagStyle xhtml := ...

Dictates that all void elements such as meta, br and input are printed as self closing tags:

<input type="submit" />
<br />

All non void elements are NOT rendered as self closing, even when empty.

<script></script>

XHTML documents, when served up from a web server, should have a Content-Type of application/xhtml+xml.

xml

Source

const static TagStyle xml := ...

Dictates that ALL empty tags are self-closing and void tags have no special meaning:

<input type="submit" />
<script />

XML documents, when served up from a web server, should have a Content-Type of text/xml or application/xml depending on usage