h4

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2026 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(nodes ...node.Node) *element

New Creates a new h4 element with the given child nodes. Example: h4.New(text.Text("Detailed Point")) Renders: <h4>Detailed Point</h4>

func RawText

func RawText(str string) *element

RawText Creates a new h4 element with raw text content as unescaped HTML. Example: h4.RawText("<small>Detail</small> Heading") Renders: <h4><small>Detail</small> Heading</h4>

func RawTextf

func RawTextf(format string, args ...any) *element

RawTextf Creates a new h4 element with formatted raw text content as unescaped HTML using text.RawTextf. Example: h4.RawTextf("Hello <em>%s</em>", "World") Renders: <h4>Hello <em>World</em></h4>

func Static

func Static(str string) *element

Static Creates a new h4 element with static text content. Example: h4.Static("Hello World") Renders: <h4>Hello World</h4>

func Text

func Text(str string) *element

Text Creates a new h4 element with text content (HTML-encoded). Example: h4.Text("<small>Detail</small> Heading") Renders: <h4>&lt;small&gt;Detail&lt;/small&gt; Heading</h4>

func Textf

func Textf(format string, args ...any) *element

Textf Creates a new h4 element with formatted text content using text.Textf. Example: h4.Textf("Hello %s", "World") Renders: <h4>Hello World</h4>

Types

type Element

type Element = element

Element is an exported alias for the private element type

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL