Skip to content
/ party Public

Simple Go web template handler that support partial templates

License

Notifications You must be signed in to change notification settings

ymonk/party

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Party Template Handler for Go Web development

Web Template handler that supports partial template.

Put your template files in ./template directory;

Put your partial template files in ./template/partial directory

In your template file, use:

{{include "partial_filename"}}

to include the partial template.

Create a template handler with: party.New(filename string, data map[string]interface{}, development bool)

If the 'development' argument is true, use dyanamic template that facilitate development-time flexibility: change the template file and refresh browser to see the result. Otherwise, use static template that maximize the run-time speed.

That's it, enjoy!

About

Simple Go web template handler that support partial templates

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages