I've added in a change to allow the default SimpleView implementation to be replaced by a custom View implementation.
Because all templates are parsed when NewMVC is called, there is no way to have templates that rely on other templates in the views directory. This change allows us to define supporting templates and add functions also.
I've added in a change to allow the default SimpleView implementation to be replaced by a custom View implementation. Because all templates are parsed when NewMVC is called, there is no way to have templates that rely on other templates in the views directory. This change allows us to define supporting templates and add functions also.
Example usage:
utronView.SetViewFactory(func(viewDir string)(utronView.View, error){ return view.NewComplexView("fragments", viewDir, views.FuncMap) })
`