I am using Assetic with a symfony2 application which mostly works fine.
One thing that is bugging me though is that in the dev enviroment (app_dev.php) assetic onelines my javascript files. This is a pain in the ass to debug. (Guess what : the error is on line 1 … duhh )
Is there a way to tell Assetic not to oneline the js files in the dev enviroment ?
For the moment I have : (config.yml)
# Assetic Configuration
assetic:
debug: %kernel.debug%
use_controller: false
bundles: [ ]
# java: /usr/bin/java
filters:
cssrewrite: ~
# closure:
# jar: %kernel.root_dir%/java/compiler.jar
yui_css:
jar: "%kernel.root_dir%/Resources/java/yuicompressor-2.4.7.jar"
yui_js:
jar: "%kernel.root_dir%/Resources/java/yuicompressor-2.4.7.jar"
And in config_dev.yml :
assetic:
use_controller: true
You should disable minification in debug mode. See this document for more info:
http://symfony.com/doc/master/cookbook/assetic/yuicompressor.html#disable-minification-in-debug-mode