Title: RE: [Tapestry-developer] Why not let components be declared that aren't used?

Thanks... I already have an older version of your tool that I never got around to integrating into my build (shame on me). But frankly the problem eventually disappeared for me on its own - I internalized the right habits.

I think the ideal setup would be to have compile-time validation of templates and components using your tool (which you could turn off if you liked) and no dynamic validation (or at least the optoin to turn it off). The fundamental question is, why should Tapestry blow up when a component that is declared is not used (for instance, a Swing app wouldn't care)? It's a nice feature to be able to be able to automatically detect cruft when you're in cleanup mode, but when you're in development mode you probably want the framework to be more tolerant of cruft.

What do other people think about this particular Tapestry hiccup?

-----Original Message-----
From: Mind Bridge [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, September 10, 2002 1:02 PM
To: Phil Surette; Tapestry Developer (E-mail)
Subject: Re: [Tapestry-developer] Why not let components be declared that aren't used?


Um...
For Tapestry 2.0.x I have a validator that checks your application for precisely this kind of problems at build time. You can run it as part of your Ant script or as a standalone application. It will find a lot of different problems, not only this one. I will send you a copy.

I am, er, working on a 2.2 version that will be closely integrated with Tapestry, but I am not ready with it yet.
-mb
 
 Phil Surette wrote:
We're using Tapestry 2.0.3. A new developer in my group is getting his feet wet in Tapestry and he just came across an annoyance that I recall from my first days with it.

When you declare a component in a .jwc file but don't reference it in the corresponding html template, you get an error when you try to access the page telling you that the component is unused. While this is certainly a good feature in some cases, it can also be annoying.  I understand that on a production system you typically won't want the overhead of unused components but during development when you are trying different things it's nice to be able tinker with the .html and jwc. files independently. As things stand now, you have to go though a complete build/deploy/test cycle before the error will crop up if you've forgotten to comment out a component that you've removed from the html.

Is there some parameter that I'm unaware of which you can use to turn off enforcement of this total mapping between the .html and .jwc files? If not, have others found this to be annoying? We don't use Spindle... perhaps Spindle solves this problem for you??


 




Do You Yahoo!?
Yahoo! Finance - Get real-time stock quotes

Reply via email to