On Wednesday, June 25, 2003, at 11:48 AM, David Graham wrote:
<custom:label property="fieldName"/>

Where the form name is obtained from the parent <html:form> tag, and
the key name defaults to FormName.fieldName.  Is that an unreasonable
default behavior?  I shy away from making "conventions" be built-in,
but duplication also sucks.  Thoughts?

Shortcuts like that are very confusing to people trying to maintain your
app. Transparency is a *very* important feature of tags which is why key
should be the full key name into the resources and property should specify
the form field just like other Struts tags. It's very confusing for users
to try and figure out what kind of magic a tag is performing and I don't
want to answer a lot of struts-user questions on what should be a simple
tag. I will *always* use more keystrokes if it makes the app clearer.

I agree with you a bit on this, for sure.


But duplication is something I work very hard to avoid. XDoclet works wonders in lots of ways, for example.

As long as this new tag is easily subclassable then life will be grand, but with that kind of duplication in our environment where we do follow the FormName.fieldName resource key conventions I cannot justify the unnecessary duplication.

Erik


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to