Back to godoc.org
bosun.org / cmd / bosun / conf / template

Package template

v0.0.0-...-8a7cd2d
Latest Go to latest

The latest major version is .

Published: Jun 18, 2020 | License: MIT | Module: bosun.org

Overview

Package template is a thin wrapper over go's text/template and html/template packages. It allows you to use either of them with a single api. Text or HTML are inferred from the template name

Index

type FuncMap

type FuncMap map[string]interface{}

type Template

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

func Must

func Must(t *Template, err error) *Template

func New

func New(name string) *Template

func (*Template) Execute

func (t *Template) Execute(w io.Writer, ctx interface{}) error

func (*Template) Funcs

func (t *Template) Funcs(fm FuncMap) *Template

func (*Template) New

func (t *Template) New(name string) *Template

func (*Template) Parse

func (t *Template) Parse(text string) (*Template, error)

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier