template

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2024 License: AGPL-3.0 Imports: 4 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
}

Engine is a template engine

func NewEngine

func NewEngine(templates embed.FS) (*Engine, error)

NewTemplateEngine creates a new template engine from the given templates

func (*Engine) Render

func (e *Engine) Render(name string, data any) ([]byte, error)

Render renders the template with the given name and data

Jump to

Keyboard shortcuts

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