Your understanding is correct, root path of context is src/main/webapp
as root context-folder and for classpath src/main/resources.
Generally I tend to put js libraries or page wide css as context assets
(src/main/webapp/js or src/main/webapp/css) and very specific artifacts
(e.g. related to one component only) as classpath asset.
Jason Tan schrieb:
I'm having trouble understanding the difference between classpath vs.
context assets -- when is it better to use one or the other? Right now I've
been putting Javascript and CSS under src/main/webapp/ , and referencing it
old-school using <script src="foo.js" type="text/javascript" ></script> but
am learning about the new @IncludeJavaScriptLibrary annotation. It appears
to use classpath assets though, and if I understand it correctly, expects
files to be in src/main/resources. Another advantage of classpath assets
appears to be versioning for cache-busting (although it looks like 5.1 will
include this for context assets too?). Should I be putting my JS/CSS/static
images in src/main/resources, packaged with .tml files?
Anyway, any sort of clarification would be appreciated.
Thanks,
Jason
--
manuel aldana
ald...@gmx.de
software-engineering blog: http://www.aldana-online.de
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org