Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( TagOpen = []byte("<optgroup") TagClose = []byte("</optgroup>") AttrLabel = []byte(" label=\"") AttrDisabled = []byte(" disabled") )
Byte constants for HTML rendering.
Functions ¶
func Labelled ¶ added in v0.3.0
Labelled Creates an optgroup with a label and child option elements. The label is displayed as a heading above the grouped options in the browser's dropdown. This is the most common pattern since the label attribute is essential for usability. Example: optgroup.Labelled("Colours", option.Option("red", "Red"), option.Option("blue", "Blue")) Renders: <optgroup label="Colours"><option value="red">Red</option><option value="blue">Blue</option></optgroup>
Types ¶
Click to show internal directories.
Click to hide internal directories.