Perhaps you could try this. In your template, have a component that grabs it's id from the page like so:

<div t:id="${componentId}"/>

I'm not sure if T5 allows expansions here, but you can try this and maybe a prop: binding. Assuming you're able, add this in your page class:

public String getComponentId() {
   return componentId;
}

So you have a page property componentId whose value is decided by whatever logic you'll need. Lastly you'll need to declare your components within your page class, using @Component annotations - of course your componentId property would have to match one of these.

This all hinges on whether or not T5 will allow prop: or expansions in the t:id parameter, so give it a try.

sincerely,
chris

johnowenatala wrote:
Hi, i have a place in a page where i wanna put a component, but which
component is desided in runtime (can be from configuration or from request
parameters).
I tried to do this by putting a delegate component, but i couldn't inject in
runtime an unknowed component in compilation time.
What do you think i can do? Is this possible?


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

Reply via email to