changcheng / wro4j

Automatically exported from code.google.com/p/wro4j
0 stars 0 forks source link

CSS / JS minifying does not work anylonger #492

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

Only use the minimization for css / js

What is the expected output? What do you see instead?
The output of css and js should be received in one line, but the files are only 
copied together without being minified

What version of the product are you using? On what operating system?
1.4.7

Please provide any additional information below.

Original issue reported on code.google.com by noctur...@googlemail.com on 19 Jul 2012 at 9:37

GoogleCodeExporter commented 9 years ago
Please provide more details.

Original comment by alex.obj...@gmail.com on 28 Jul 2012 at 7:22

GoogleCodeExporter commented 9 years ago
Cannot reproduce. Please provide a detailed description of your configuration. 
The following details are important:
1) How the model looks like?
2) Do you use wro4j as a runtime or build time solution
3) What processors do you use?
4) How configuration looks like?

Original comment by alex.obj...@gmail.com on 29 Jul 2012 at 12:04

GoogleCodeExporter commented 9 years ago
I'm currently not at work so I can't provide those information today but far as 
I remember I used the Spring configuration - with the normal wro filter there 
wasnt any issue. I will provide the setup tomorrow.

Original comment by noctur...@googlemail.com on 29 Jul 2012 at 2:06

GoogleCodeExporter commented 9 years ago
Ok. Now I'm at work and I can post my settings. I'm using the 
org.springframework.web.filter.DelegatingFilterProxy and in the wro.xml I only 
use one group tag with some js / css tags in it. Those js / css tags do not 
have any minimize="true" tags, but If I set it the whitespaces (cr / ls) are 
still in the merged files.

Original comment by noctur...@googlemail.com on 31 Jul 2012 at 2:17

Attachments:

GoogleCodeExporter commented 9 years ago
Since you are using ConfigurableWroFilter and specify the configuration options 
inside a properties file, it is expected to provide also the processors to use, 
otherwise no processors are applied. As result the resources are just merged. 

Original comment by alex.obj...@gmail.com on 31 Jul 2012 at 2:22

GoogleCodeExporter commented 9 years ago
I will close the issue with invalid resolution. Feel free to reopen it if you 
still consider this is a bug.

Original comment by alex.obj...@gmail.com on 31 Jul 2012 at 3:11

GoogleCodeExporter commented 9 years ago
But this is somehow misleading, because if I create a normal wro filter with 
exact the same properties it works. The next question is how to set the 
handlers - I currently don't know how to do so in the properties

Original comment by noctur...@googlemail.com on 1 Aug 2012 at 6:28

GoogleCodeExporter commented 9 years ago
I will update the javadoc of the ConfigurableWroFilter. 
Configurable means that it can be (and sometimes require) configuration. So it 
is not the same thing as normal WroFilter which by default uses some processors.

The documentation about RequestHandlers can be found here: 
http://code.google.com/p/wro4j/wiki/RequestHandler

Adding a custom handler is as simple as extending invoking 
WroFilter.requestHandlerFactory(RequestHandlerFactory)

Original comment by alex.obj...@gmail.com on 1 Aug 2012 at 6:41

GoogleCodeExporter commented 9 years ago
Thanks :-) I did it this way: 

postProcessors=yuiCssMin,yuiJsMinAdvanced

This adds the processors I want. 

It is great to get a response to requests so fast. Great work!

Original comment by noctur...@googlemail.com on 1 Aug 2012 at 6:51