On Wed, 09 Jan 2013 06:24:19 -0200, Michael Wyraz <michael.wy...@evermind.de> wrote:

Hi,

Hi!

I had a closer look to the problem (reported by some of our developers):
There are a few really big pages. Formerly these where separate pages but since we changed everything to ajax navigation, these pages are consolidated to one page.

Howard is way more suited for saying that than me, but I really think you've just described the source of your problem: you have a very huge page that contains your whole application. It's not just an über-component, which is a Tapestry anti-pattern, it's an über-page, which is an anti-pattern too. When you change something, you end up making Tapestry reload not just one page, but the whole application, as the application is inside one page.

There's absolutely no need to consolidate all pages into one for what you're doing. Just put different stuff wrapped in blocks, put these blocks in different pages, use ComponentSource to get a page instance, getBlock() to get the block, the Delegate component or event handler return value to render the block, Environment to pass information to the blocks. This isn't the only solution (maybe you could @InjectPage the pages, set properties on them and use getBody() or getBlock() instead of ComponentSource and Environment, but I haven't tested that_, but it's basically what the BeanModel-based components (Grid, BeanEditor, BeanEditForm, BeanDisplay) do.

--
Thiago H. de Paula Figueiredo

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

Reply via email to