News for hackers. Stuff that matters.
Re:A RESTful Micro-Framework in Go by unoti on Sunday January 26, 2014 @01:52PM (#7126258)
Here's one possible example. At the top of this thread, there's a statement about how Go templates don't support inheritance-- embedding one template within another as Django and Jinja do[1]. I personally consider this a requirement, because the old school way of having headers and footers in separate templates is radically inferior.

Go doesn't offer a clear simple way to do this in their builtin template library. But it turns out, it really is possible to do it, as described in this thread on Stack Exchange[2]. I bookmarked that so that I can boil it down into some simple-to-reuse code if I ever bite the bullet and start using Go for the presentation layer on a major website. What they're doing there is a cool technique, but it's not simple to use out of the box.

1. https://sites.google.com/site/usfcomputerscience/django-temp...

2. http://stackoverflow.com/questions/11467731/is-it-possible-t...

There are no comments on this comment yet.