Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Play Framework CSS/JS aggregation

Is there a version of a press module (http://www.playframework.com/modules/press) for Play Framework 2 to minifi and aggregate JS and CSS? Are there alternatives? I hate 20 files being included into my templates.

Thanks!

like image 604
Greg R Avatar asked May 16 '26 08:05

Greg R


2 Answers

Play supports LESS directly, you can create one less file where you import all the needed CSS files. In this way you can get all your CSS in a single request.

like image 132
nylund Avatar answered May 19 '26 01:05

nylund


You could look into integrating wro4j into your build: https://code.google.com/p/wro4j/ It's quite flexible when it comes to combining js/css files.

like image 33
overthink Avatar answered May 19 '26 02:05

overthink



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!