package hstring

import "github.com/gohugoio/hugo/common/types/hstring"

Index

Types

type HTML

type HTML string

HTML is a string that represents rendered HTML. When printed in templates it will be rendered as template.HTML and considered safe so no need to pipe it into `safeHTML`. This type was introduced as a wasy to prevent a common case of inifinite recursion in the template rendering when the `linkify` option is enabled with a common (wrong) construct like `{{ .Text | .Page.RenderString }}` in a hook template.

func (HTML) PrintableValue

func (s HTML) PrintableValue() any

func (HTML) String

func (s HTML) String() string

Source Files

stringtypes.go

Version
v0.144.2 (latest)
Published
Feb 19, 2025
Platform
linux/amd64
Imports
2 packages
Last checked
13 hours ago

Tools for package owners.