I would have to side with Andy and say that this is an
excellent question that I was wondering how to do
myself.

I have been staying away from putting any pages into
libraries just for this reason.

It's fine to me that a library component has a
dependency on a particular component (still reusable
to me).  What is important is that I can provide to
the component or page what the particular
implementation of the component is (i.e. Border)

I have a Border component UI that I like to change on
a per project basis. (i know, use css, but that's not
enough.)  This is easily accomplished by defining the
specific Border component in my application
specification.
Since each of my pages (in each of the different
projects) refer to Border in the default application
namespace, it works well for me.

However, if my pages were encapsulated within a
library, this would not work since the @Border would
not resolve since it is not in that libraries
namespace.


It would be nice to be be able to override a library
component from within one's application specification.

Thanks.

--- Mind Bridge <[EMAIL PROTECTED]> wrote:

> I agree with Viktor on this one, but here is one
> other alternative just in
> case:
> 
> Your Border component can take a Block as a
> parameter and then render it
> where it has to go using RenderBlock.
> Alternatively, it can actually take a component as a
> parameter and renderer
> it using Delegator.
> 
> The only downside is that the code every time you
> use your Border becomes a
> bit bigger, as you need to declare the parameter (as
> long as it is
> required):
> 
> <span jwcid="@lib:Border" section="...">
> ...
> </span>
> 
> ----- Original Message ----- 
> From: <[EMAIL PROTECTED]>
> To: <[email protected]>
> Sent: Friday, June 10, 2005 5:33 PM
> Subject: referencing an application component from
> inside a library
> 
> 
> > I am trying to bundle a Border component into a
> library. That way, the
> > cororate look and feel would be easily plugable in
> future projects.
> >
> > Unfortunatly the component in the library needs to
> reference a component
> > outside the library in the application namespace.
> How can I reference
> > this component?
> >
> > Andy Pahne
> >
> >
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> >
> >
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 


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

Reply via email to