Sent from my iPad

> On Feb 10, 2014, at 7:00 PM, Russell Keith-Magee <russ...@keith-magee.com> 
> wrote:
> 
> 
>> On Tue, Feb 11, 2014 at 9:31 AM, Luke Sneeringer <l...@sneeringer.com> wrote:
>>> On Feb 10, 2014, at 12:16 PM, Carl Meyer <c...@oddbird.net> wrote:
>>> 
>>> It's a problem that we are unable to do things
>>> that would otherwise be no-brainers (e.g. rendering form widgets using
>>> templates rather than by concatenating strings of HTML in Python code)
>>> because our default templating language is too slow.
>> 
>> The deliberate hobbling aspect also makes situations like this that should 
>> be no-brainers into painful slogs. Form widgets are a great example beyond 
>> this, too, because customizing HTML for particular form elements (e.g. 
>> adding size="30" to one input field) is an absolute pain. The blessed way 
>> involves overwriting the field, which requires copying every single relevant 
>> attribute of the model (and then double-maintaining changes).
>> 
>> The Flask extension's mechanism is {{ field(size=30) }}. Done.
> 
> Please don't fall into the trap of assuming I'm mentally impaired in some 
> way. 

I intended no offense. I have great respect for you and for your intellect and 
reasoning. 

> I'm also aware of the ways it can be abused. I'd be able to mount a 
> reasonable argument that {{ field(size=30) }} is a problem, not a feature 
> (whats the magical significance of 30? What happens if you make a site-wide 
> decision to extend all size=30 fields to size=40? etc. And, to be clear, I'm 
> not interested in having *this* specific argument in long form. Just be aware 
> that I'd make it, and that it's the argument that underpins the original 
> design decisions of Django's template language).
> 
> I'm also aware that this is *my* analysis, and that others will come to a 
> different conclusion, based on their own values, priorities, experiences, and 
> engineering taste. 
> 
> This doesn't make *either* analysis wrong. It means different people value 
> different things. 

However, Jinja's approach makes it very easy to decide on the side of the line 
that you are proposing. Django's approach makes it very hard to go in the 
converse route.

Best Regards,
Luke

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/C21881D3-7FFC-4D01-9210-6B9D53BCD8E0%40sneeringer.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to