Open kjosib opened 4 years ago
Just a thought: the template stuff was originally conceived to be little more than string.format(...)
with some smarts about the fact we're dealing in HTML (most of the time). It's grown a few bells and whistles over time. It's at about that level where I wonder if a bunch of simple hand-coded string manipulations and regex library calls remains the right approach. I certainly wouldn't want to add many more features this way.
Adding complexity and texture to the template language can and has lead to a more comfortable style of working, but to avoid a stinky knock-off of django and actually try to advance the art, I'd rather draw the semantic boundaries in a completely different manner. The basic idea:
LoopTemplate
class.Anyway, this is going to simmer for a while.
Probably. The protocol service can rely on it for built-in/generic error/status messages. I'd feel more comfortable if the
iolist
stuff wasn't so tightly tied to the idea of serving a HTTP response, though. For the moment it doesn't impact the API.