Skip to main content

Keep few javascript uncompressed

  3 posts   Feedicon  
Replies: 2 - Last Post: February 17, 2012 08:05
by: dmendia
showing 1 - 3 of 3
Posted: February 16, 2012 08:52 by dmendia

I want to know if is it possible to keep few javascript uncompressed from jawr.js.bundle.basedir while compression is activated.

I mean, this is the key part in our


But in some cases we want to keep some path files unalterable and uncompressed, so it can be reached from its original path by external clients.



If I try to get http://company_name/js/folder/unalterable1.js it returns a 404 error if the compression is activated. But if we change jawr.debug.on to true everything is ok. It's a customer requirement that those javascripts remain in that path, and unfortunately it cannot be changed.

I don't want to change the compression folder for the other files, because they're so many, so if I reach a hybrid solution, with compression (for jwr taglib in jsp) and everything under the /js folder untouched and reachable, it will be awsome!

I've been looking for a property in, but I don't find a clue.

Thanks in advance (and sorry if you don't understand some explanation. I'm not used to speak english).

Posted: February 16, 2012 22:56 by icefox

The only way to prevent Jawr to handle your javascript file is to set specific path mapping for the Jawr bundles.
In your web.xml, you can define your severlet mapping like this :


Here jsJawrPath will be the Jawr path prefix.

You can check the following link for more detail :

Posted: February 17, 2012 08:05 by dmendia

Thank you so much for your quick response!

I tried this yesterday, but I totally forgot the init-param mapping. Hahahaha.
Now it seems to work perfectly.

Replies: 2 - Last Post: February 17, 2012 08:05
by: dmendia
Please Confirm