I'm focusing on documentation for the moment, so code enhancements are going to be deferred.
Tapestry 3 had "the Inspector" a way of digging down through the structure of the page. I've floated the idea of a special development-mode-only query parameter that would display the structure of the page rather then render it normally. Another option was another query parameter to enable comments that would trace what components were responsible (i.e., a comment at the start and end of each component's render). On Thu, Jun 18, 2009 at 9:29 AM, Erick Erickson <[email protected]>wrote: > An utter Tapestry newbie here, although I was at some recent training > Howard > gave. > > My question is, "Given a page composed of components, is there an easy, > visual > way to analyze the structure in terms of custom components *from the > browser > *?". > The problem I'm trying to address is the most efficient way to bring > someone > new > (me, in this case <G>) up to speed on a project. > > A person can use some of the browser tools to examine the HTML, but that > doesn't relate very well back to the raw files (components) they came from. > > I hacked together a script that inserts an <img> tag in all my local copies > of > the .tml files, with a title attribute of the file path that .tml came > from. > Now, > when I'm viewing prior art I can hover over the icons I've inserted and see > the > full file path that the .tml came from. > > This allows me to figure out that component X contains component Y which > in turn contains component Z in a *visual* way, which makes it *much* > easier > > to understand the relationships between components, as well as know what > the visual result of using a component is. Of course there's no way I'd > consider > checking this in, it's strictly for local usage. This is more > proof-of-concept, but > even in this crude form I'm finding it very helpful. > > Now when presented with another page to implement, I have a better chance > of > saying "Look, page X does something similar, and uses components Y and Z. > I wonder if those components are a good place to start?". > > Of course, this messes with the formatting of the page, things move around, > etc, > but that's not important for me now. > > My question for the list is "Is anything similar already built into > Tapestry > but > I just haven't found it yet?". Or are there any best practices others have > used? > > Best > Erick > -- Howard M. Lewis Ship Creator of Apache Tapestry Director of Open Source Technology at Formos
