4 ms·
Have you tried to benchmark writing out a page with Go templates, vs GO producing a JSON API that prints out into static HTML pages with JQUERY/Handlebars? How
by dzink 9y ago
Have you tried to benchmark writing out a page with Go templates, vs GO producing a JSON API that prints out into static HTML pages with JQUERY/Handlebars? How many RPS can you get with either scenario? What is Time to First Paint and when does the page finish printing for the user?
- captncraig 9y agoGo templates are not particularly fast, but I would be astonished if the client-side way one that battle. There are faster server-side template engines in go though. One approach I particularly like is https://github.com/bouk/statictemplate https://github.com/bouk/statictemplate, which generates code from your standard go templates that makes them quite a bit faster.