You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Alfonso Quiroga <al...@gmail.com> on 2009/08/27 09:39:15 UTC

how to enable default js and css stack?

I have a little problem, if I use some t5component that needs the full
js stack (declared in ClientInfrastructure), it writes in <head> the
libs, and no problem.
But if I have a plain page with no t5 components, so none of that
js-libs are (prototype, etc)
My problem is that I created a component that NEEDS prototype, etc..
but that libs are not referenced!! So I MUST put a t5component in my
page (like EventLink) that internally uses the default js stack.

So... how can I explain to T5 that my new component needs the default
js stack? Thanks in advance!

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: how to enable default js and css stack?

Posted by Alfonso Quiroga <al...@gmail.com>.
Thanks! I think a nice way is using IncludeJavascript annotation, now
is working fine

On Thu, Aug 27, 2009 at 1:34 PM, Howard Lewis Ship<hl...@gmail.com> wrote:
> Inject @Environmental RenderSupport
>
> Invoking any of its JavaScript related functions will automatically
> trigger the inclusion of the client infrastructure (all that JS and
> CSS).
>
> Using @InlcudeJavaScriptLibrary does the same (under the covers, its a
> call to the RenderSupport.addScriptLink(). ).
>
>
> On Thu, Aug 27, 2009 at 1:24 AM, Inge Solvoll<in...@gmail.com> wrote:
>> Check the tapestry sources, I fond this now in Autocompleter mixin:
>>
>> @IncludeJavaScriptLibrary({"${tapestry.scriptaculous}/controls.js",
>> "autocomplete.js"})
>>
>> On Thu, Aug 27, 2009 at 9:39 AM, Alfonso Quiroga <al...@gmail.com>wrote:
>>
>>> I have a little problem, if I use some t5component that needs the full
>>> js stack (declared in ClientInfrastructure), it writes in <head> the
>>> libs, and no problem.
>>> But if I have a plain page with no t5 components, so none of that
>>> js-libs are (prototype, etc)
>>> My problem is that I created a component that NEEDS prototype, etc..
>>> but that libs are not referenced!! So I MUST put a t5component in my
>>> page (like EventLink) that internally uses the default js stack.
>>>
>>> So... how can I explain to T5 that my new component needs the default
>>> js stack? Thanks in advance!
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>>
>
>
>
> --
> Howard M. Lewis Ship
>
> Creator of Apache Tapestry
>
> The source for Tapestry training, mentoring and support. Contact me to
> learn how I can get you up and productive in Tapestry fast!
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: how to enable default js and css stack?

Posted by Howard Lewis Ship <hl...@gmail.com>.
Inject @Environmental RenderSupport

Invoking any of its JavaScript related functions will automatically
trigger the inclusion of the client infrastructure (all that JS and
CSS).

Using @InlcudeJavaScriptLibrary does the same (under the covers, its a
call to the RenderSupport.addScriptLink(). ).


On Thu, Aug 27, 2009 at 1:24 AM, Inge Solvoll<in...@gmail.com> wrote:
> Check the tapestry sources, I fond this now in Autocompleter mixin:
>
> @IncludeJavaScriptLibrary({"${tapestry.scriptaculous}/controls.js",
> "autocomplete.js"})
>
> On Thu, Aug 27, 2009 at 9:39 AM, Alfonso Quiroga <al...@gmail.com>wrote:
>
>> I have a little problem, if I use some t5component that needs the full
>> js stack (declared in ClientInfrastructure), it writes in <head> the
>> libs, and no problem.
>> But if I have a plain page with no t5 components, so none of that
>> js-libs are (prototype, etc)
>> My problem is that I created a component that NEEDS prototype, etc..
>> but that libs are not referenced!! So I MUST put a t5component in my
>> page (like EventLink) that internally uses the default js stack.
>>
>> So... how can I explain to T5 that my new component needs the default
>> js stack? Thanks in advance!
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: how to enable default js and css stack?

Posted by Inge Solvoll <in...@gmail.com>.
Check the tapestry sources, I fond this now in Autocompleter mixin:

@IncludeJavaScriptLibrary({"${tapestry.scriptaculous}/controls.js",
"autocomplete.js"})

On Thu, Aug 27, 2009 at 9:39 AM, Alfonso Quiroga <al...@gmail.com>wrote:

> I have a little problem, if I use some t5component that needs the full
> js stack (declared in ClientInfrastructure), it writes in <head> the
> libs, and no problem.
> But if I have a plain page with no t5 components, so none of that
> js-libs are (prototype, etc)
> My problem is that I created a component that NEEDS prototype, etc..
> but that libs are not referenced!! So I MUST put a t5component in my
> page (like EventLink) that internally uses the default js stack.
>
> So... how can I explain to T5 that my new component needs the default
> js stack? Thanks in advance!
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>