Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If separation of duties is a concern, Django's templates (IMO) get it more right than anything else.

I remember, at one point, that I felt Django templates were limiting me, and started swapping them out piecemeal for Jinja, and my designers started to absolutely hate me. Not because they had to convert anything, I converted everything by hand, but just that the amount of syntax you can cram in there keeps everything less pure.

Since then, I realized I was trying to do too much in the template and started putting things where they belonged, and now, whenever I work with Jinja or Mako, it feels a little too much like editing Wordpress themes or something in PHP.

Long story short, I learned the hard way that if you're putting logic in the templates, you're probably doing something wrong, and I agree that it is not only a reasonable design, but a very good suggestion as well.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: