internal

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TextPackage string = "text"
	HtmlPackage string = "html"
)
View Source
const (
	MissingkeyInvalid string = "invalid"
	MissingkeyZero    string = "zero"
	MissingkeyError   string = "error"
)

Variables

This section is empty.

Functions

func Execute

func Execute(w io.Writer, tmpl string, data any, opts *ExecuteOptions) error

Types

type ExecuteOptions

type ExecuteOptions struct {
	// Package is the template package to use. Defaults to TextPackage.
	Package string

	// Missingkey is the action to take when a template references a key that is not present in the data.
	// Defaults to MissingkeyInvalid.
	Missingkey string

	Funcs template.FuncMap
}

Jump to

Keyboard shortcuts

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