public static function js($content) {
        try {
            $minifier = new MatthiasMullie\Minify\JS($content);
            return $minifier->minify();
        } catch (Exception $e) {
            ob_end_clean();
            $error = $e->getMessage();
        }

        $return = <<<EOD

try {console.log('Error: Minimisation of JavaScript failed!');} catch (e) {}

// Error: $error
// Problem detected during JavaScript minimisation, please review the following code
// =================================================================================


EOD;

        return $return.$content;
    }
public static function js($content) {
        try {
            $minifier = new MatthiasMullie\Minify\JS($content);
            return $minifier->minify();
        } catch (Exception $e) {
            ob_end_clean();
            $error = $e->getMessage();
        }

        $return = <<<EOD

try {console.log('Error: Minimisation of JavaScript failed!');} catch (e) {}

// Error: $error
// Problem detected during JavaScript minimisation, please review the following code
// =================================================================================


EOD;

        return $return.$content;
    }
public static function js ( $ content ) { try { $ minifier = new MatthiasMullie \ Minify \ JS ( $ content ) ; return $ minifier -> minify ( ) ; } catch ( Exception $ e ) { ob_end_clean ( ) ; $ error = $ e -> getMessage ( ) ; } $ return =  <<<EOD

try {console.log('Error: Minimisation of JavaScript failed!');} catch (e) {}

// Error: $error
// Problem detected during JavaScript minimisation, please review the following code
// =================================================================================


EOD ; return $ return . $ content ; }
Minify JS code.

@param string $content
@return string minified JS code
Minify JS code .