Documentation ¶
Index ¶
- Constants
- type Asset
- type Assets
- type ContentGenerator
- type Engine
- func (engine *Engine) AssetURL(asset string) (string, error)
- func (engine *Engine) Generate(output string) error
- func (engine *Engine) HandlePath(newPath string, loader ContentGenerator) error
- func (engine *Engine) MinifyHTML(content []byte) ([]byte, error)
- func (engine *Engine) MinifyJS(content []byte) ([]byte, error)
- func (engine *Engine) MinifyJson(content []byte) ([]byte, error)
- func (engine *Engine) RenderTemplate(template_ string, symbolMap map[string]string) ([]byte, error)
- func (engine *Engine) ScriptURL(script string) (string, error)
- type Script
- type Scripts
- type Templates
Constants ¶
View Source
const ( JSExtension = "js" JsonExtension = "json" HTMLExtension = "html" )
View Source
const ( PathAlreadyInUse = "Path %s is already being in use" TemplateNotFound = "Template %s not found" AssetNotFound = "Asset %s not found" ScriptNotFound = "Script %s not found" ScriptIsNotAGoPackage = "Script %s is not a go package" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Assets ¶
func LoadAssets ¶
type ContentGenerator ¶
type Engine ¶
type Engine struct { Templates Templates Scripts Scripts Assets Assets // contains filtered or unexported fields }
func (*Engine) HandlePath ¶
func (engine *Engine) HandlePath(newPath string, loader ContentGenerator) error
func (*Engine) RenderTemplate ¶
type Scripts ¶
func LoadScripts ¶
Click to show internal directories.
Click to hide internal directories.