Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( TagOpen = []byte("<dd") TagClose = []byte("</dd>") )
Byte constants for HTML rendering.
Functions ¶
func New ¶
New Creates a new dd element with child nodes. Example: dd.New(text.Text("A large feline inhabiting Bodmin Moor.")) Renders: <dd>A large feline inhabiting Bodmin Moor.</dd>
func RawText ¶
func RawText(str string) *element
RawText Creates a new dd element with raw text content. Uses text.RawText which is not HTML-escaped. Example: dd.RawText("A large feline inhabiting Bodmin Moor.") Renders: <dd>A large feline inhabiting Bodmin Moor.</dd>
func RawTextf ¶
RawTextf Creates a new dd element with formatted raw text content. Uses text.RawTextf which is not HTML-escaped. Example: dd.RawTextf("A large feline inhabiting %s.", "Bodmin Moor") Renders: <dd>A large feline inhabiting Bodmin Moor.</dd>
func Static ¶
func Static(str string) *element
Static Creates a new dd element with static text content. Uses text.Static which is not HTML-escaped and is JIT-optimisable. Example: dd.Static("A large feline inhabiting Bodmin Moor.") Renders: <dd>A large feline inhabiting Bodmin Moor.</dd>