templates

package
v4.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2021 License: MIT Imports: 13 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTemplates

func GetTemplates(dir, ext string) ([]string, error)

GetTemplates list files by extension

func ResponseHTMLTemplate

func ResponseHTMLTemplate(tpl *template.Template, w http.ResponseWriter, content interface{}, status int) error

ResponseHTMLTemplate write template name from given template into writer for provided content with HTML minification

func ResponseXMLTemplate

func ResponseXMLTemplate(tpl *template.Template, w http.ResponseWriter, content interface{}, status int) error

ResponseXMLTemplate write template name from given template into writer for provided content with XML minification

func WriteTemplate

func WriteTemplate(tpl *template.Template, w io.Writer, content interface{}, mediatype string) error

WriteTemplate write template name from given template into writer for provided content with given minification

Types

This section is empty.

Jump to

Keyboard shortcuts

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