view

package
v0.5.16 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TextContent added in v0.2.33

func TextContent(tplContent string, viewData interface{}, includeFiles ...string) (res string)

TextContent 根据模板内容渲染文本类型模版

func TextPath

func TextPath(tplPath string, viewData interface{}, includeFiles ...string) (res string)

TextPath 渲染文本

Types

type AppTemplate added in v0.1.4

type AppTemplate struct {
	ViewName    string
	ViewPath    string
	IncludeTmpl []string
	ShowData    map[string]interface{}
	// contains filtered or unexported fields
}

func ContextTmpl added in v0.1.4

func ContextTmpl(viewName string, includeFiles ...string) *AppTemplate

func (*AppTemplate) Assign added in v0.1.4

func (t *AppTemplate) Assign(name string, value interface{}) *AppTemplate

func (*AppTemplate) Assigns added in v0.1.4

func (t *AppTemplate) Assigns(values interface{}) *AppTemplate

func (*AppTemplate) Render added in v0.1.4

func (t *AppTemplate) Render() (viewHtmlRes string, err error)

func (*AppTemplate) RenderText added in v0.1.4

func (t *AppTemplate) RenderText() (viewHtmlRes string, err error)

Jump to

Keyboard shortcuts

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