Re:Django Book 1.0 online
by staunch on Monday December 17, 2007 @12:16AM
(#90246)
I like not having a lot of heavy code inside my templates. The only stuff I do there is displaying values, formatting, and some simple logic. Isn't this one of the core principles of MVC?
[ Parent
| on HN ]
Exactly. Having a "watered-down template language" is a good thing.
The problem is arguably that the indirection is really, really costly. Just today I wrote a custom template tag I needed in order to factor out some functionality common to every view on my application. In RoR it would have been maybe 2 lines, but that custom tag was more like 15.
I still adore Django for its efforts to remove all the "magic" code, though.