Am 30.05.2012 17:51, schrieb Damon Courtney:
> And that's my point.  If it matters, YOU should pass -id X instead of letting 
> us generate one.  In other words:
> 
> set f [form #auto] ;
> 
> $f checkbox foo -label Foo ; ## Note, I don't care about an ID here.
> $f checkbox bar -label Bar ; ## Don't care about this one either.
> $f checkbox moo -label Moo -id bar-checkbox ; ## I'm going to style this or 
> use Javascript, so I need its ID.
> 
> If you are letting US auto generate IDs and then using those in your CSS and 
> JS, you're a bad, bad developer.  One, tiny change to your HTML, and your 
> shit is busted.  If you rejiggered your form to move Bar above Foo, you just 
> screwed up their ID you were relying on.
> 
> The documentation should say that if you don't give us a -id, we'll 
> auto-generate one that is unique.  That's it.  We can give people rope to 
> hang themselves, but we don't have to put it around their neck and give them 
> a push.

I agree.

I would document the way autogenerated IDs are build, e.g. say, that
they always start with "autogen".

Thank you,
Harald

---------------------------------------------------------------------
To unsubscribe, e-mail: rivet-dev-unsubscr...@tcl.apache.org
For additional commands, e-mail: rivet-dev-h...@tcl.apache.org

Reply via email to