Skip to content

Commit

Permalink
Update fs.go
Browse files Browse the repository at this point in the history
updated template interface to expose the `ExecuteTemplate` method
  • Loading branch information
adoublef authored May 24, 2024
1 parent 8cbd323 commit cacb38f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions html/template/fs.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ func NewFS(fsys fs.FS) *FS {
type Template interface {
// Execute applies a parsed template to the specified data object, writing the output to wr
Execute(wr io.Writer, data any) error
// ExecuteTemplate applies the template associated with t that has the given
// name to the specified data object and writes the output to wr.
ExecuteTemplate(wr io.Writer, name string, data any) error
}

var (
Expand Down

0 comments on commit cacb38f

Please sign in to comment.