Documentation
¶
Overview ¶
Package templates provides plugins access to Go templates.
Configuration: |-----------------------|-----------------------| | Env | JSON | | ----------------------|-----------------------| | TEMPLATES_ALWAYSPARSE | templates.alwaysparse | | TEMPLATES_DIRS | templates.dirs | |-----------------------|-----------------------|
Index ¶
Constants ¶
View Source
const PluginName = "templates"
Constant name for identifying the templates plugin.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TemplateData ¶
type TemplateData struct { Data interface{} Config map[string]interface{} }
type TemplatePlugin ¶
type TemplatePlugin struct {
// contains filtered or unexported fields
}
TemplatePlugin exposes utilities for reading and rendering go templates.
func (*TemplatePlugin) Load ¶
func (p *TemplatePlugin) Load(dirs []string) error
Load templates (*.tmpl) contained within the provided directory and all sub-directories.
Click to show internal directories.
Click to hide internal directories.