Open dav-m85 opened 3 years ago
I need to replace a partial before Exec (usecase: in dev, want to reload a partial when I edit it)
raw := `{{>partial}}` tpl, _ := raymond.Parse(raw) tpl.RegisterPartial("partial", "Bloubi") tpl.MustExec(tpl) // "Bloubi" tpl.ReplacePartial("partial", "Boulga") tpl.MustExec(tpl) // "Boulga"
This is the code for this :)
I need to replace a partial before Exec (usecase: in dev, want to reload a partial when I edit it)
This is the code for this :)