template

package
v0.0.1-rc2 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Engine

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

func New

func New(templateDir, variablesDir, outputDir string) *Engine

func (*Engine) GenerateContent

func (e *Engine) GenerateContent(tplPath, outputPath string) (string, error)

GenerateContent 生成模板内容但不写入文件

func (*Engine) GetVariables

func (e *Engine) GetVariables() map[string]interface{}

GetVariables 返回模板引擎中加载的所有变量

func (*Engine) LoadVariables

func (e *Engine) LoadVariables(variableFiles []string) error

Jump to

Keyboard shortcuts

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