tpls

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Templates

type Templates struct {
	// contains filtered or unexported fields
}

Templates is used for templates rendering.

func New

func New(values map[string]interface{}, funcMap template.FuncMap) *Templates

New created template renderer with values to replace.

func (*Templates) Render

func (t *Templates) Render(s string) string

Render applies values and renders final output.

func (*Templates) Validate

func (t *Templates) Validate(s string) error

Validate verifies if template is correct.

Jump to

Keyboard shortcuts

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