func (tmplEng TemplateEngine) GenerateAndExecuteTemplate(w http.ResponseWriter, viewName, pageName string, data interface{}) error {
	tmpl, err := tmplEng.GenerateTemplate(viewName)
	if err != nil {
		return err
	}
	pageData := PageData{pageName, data, tmplEng.Config}
	return tmpl.Execute(w, pageData)
}
// GenerateAndExecuteTemplate will make a call to GenerateTemplate and then
// it will create a PageData struct and pass it
GenerateAndExecuteTemplate will make a call to GenerateTemplate and then
it will create a PageData struct and pass it
// GenerateAndExecuteTemplate will make a call to GenerateTemplate and then // it will create a PageData struct and pass it
func (tmplEng TemplateEngine) GenerateAndExecuteTemplate(w http.ResponseWriter, viewName, pageName string, data interface{}) error {
	tmpl, err := tmplEng.GenerateTemplate(viewName)
	if err != nil {
		return err
	}
	pageData := PageData{pageName, data, tmplEng.Config}
	return tmpl.Execute(w, pageData)
}
func ( tmplEng TemplateEngine ) GenerateAndExecuteTemplate ( w http . ResponseWriter , viewName , pageName string , data interface { } ) error { tmpl , err := tmplEng . GenerateTemplate ( viewName ) if err != nil { return err } pageData := PageData { pageName , data , tmplEng . Config } return tmpl . Execute ( w , pageData ) }
GenerateAndExecuteTemplate will make a call to GenerateTemplate and then
it will create a PageData struct and pass it
GenerateAndExecuteTemplate will make a call to GenerateTemplate and then it will create a PageData struct and pass it