2 ms·
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
by staunch 19y ago
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?
- bdr 19y agoExactly. Having a "watered-down template language" is a good thing.
- tel 19y agoThe 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.
- deleted 19y ago[deleted]