示例#1
0
文件: shortcode.go 项目: jcdny/hugo
func GetTemplate(name string, t bundle.Template) *template.Template {
	if x := t.Lookup("shortcodes/" + name + ".html"); x != nil {
		return x
	}
	return t.Lookup("_internal/shortcodes/" + name + ".html")
}
示例#2
0
文件: shortcode.go 项目: 4honor/hugo
func GetTemplate(name string, t bundle.Template) *template.Template {
	return t.Lookup("shortcodes/" + name + ".html")
}