Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultOptions = Options{ RootDir: "web/templates", GlobPattern: "*.gotmpl", FuncMaps: []template.FuncMap{}, FuncMapper: defaultFuncMapper, }
DefaultOptions provides the base options when creating a new Renderer.
Functions ¶
This section is empty.
Types ¶
type FuncMapper ¶
FuncMapper provides a template.FuncMap from an echo.Context.
type Options ¶
type Options struct {
// The root directory of the templates.
RootDir string
// The glob pattern to match when initializing.
GlobPattern string
// Optional list of [template.FuncMap] objects.
FuncMaps []template.FuncMap
// Optional [FuncMapper]
FuncMapper FuncMapper
}
Options configure the Renderer.
type Renderer ¶
type Renderer struct {
// contains filtered or unexported fields
}
Renderer provides a custom implementation of echo.Renderer using template.Template.
Click to show internal directories.
Click to hide internal directories.