Break
Break renders br or wbr for controlled inline wrapping.
github.com/fastygo/templ/ui
Summary
Break renders br or wbr for controlled inline wrapping.
Use Cases
Render intentional line breaks in addresses
Add optional break points in long tokens
Semantics
Type br renders a line break
Type wbr or word renders an optional word break
Example type.br
import "github.com/fastygo/templ/ui"
templ Example() {
@ui.Break(ui.BreakProps{})
}
import "github.com/fastygo/templ/ui"
templ Example() {
@ui.Break(ui.BreakProps{})
}Example type.wbr
import "github.com/fastygo/templ/ui"
templ Example() {
@ui.Break(ui.BreakProps{Type: "wbr"})
}
import "github.com/fastygo/templ/ui"
templ Example() {
@ui.Break(ui.BreakProps{Type: "wbr"})
}API
Class · string — role: style-extension
Type · string — role: break-type; enum: br|wbr|word; default: br