roots/bedrock — pull request #5 by nmec (2013-12-19 10:15:11+00:00)
Title: Add SCRIPT_DEBUG constant to allow loading of optimised CSS/JS.

Adds the constant if it has been defined in the env file, otherwise defaults to true on development and false on staging and prod.

Theme developers using a build script for their CSS/JS can use this to enqueue the un-minified version of scripts for debugging during development and switch to the concatenated/minified version on staging and production. For example:

```php
function my_enqueue_function() {

if ( defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ) {
wp_enqueue_style( 'example-lib-1' );
wp_enqueue_style( 'style-dev' );

wp_enqueue_script( 'jquery' );
wp_enqueue_script( 'app' );
} else {
wp_enqueue_style( 'build-css' );
wp_enqueue_style( 'build-js' );
}
}
```

More info on [SCRIPT_DEBUG](http://codex.wordpress.org/Editing_wp-config.php#Debug)