≡

wincent.dev

  • Products
  • Blog
  • Wiki
  • Issues
You are viewing an historical archive of past issues. Please report new issues to the appropriate project issue tracker on GitHub.
Home » Issues » Feature request #1437

Feature request #1437: Switch to Google Closure compiler for Javascript minimization

Kind feature request
Product wincent.dev
When Created 2009-11-07T07:03:44Z, updated 2009-11-12T17:41:30Z
Status closed
Reporter Greg Hurrell
Tags no tags

Description

Some quick testing shows that Google's newly released Closure can produce smaller Javascript files than the Yahoo compressor that I am currently using.

Comments

  1. Greg Hurrell 2009-11-09T12:50:17Z

    Having some problems in getting this to work. If I copy and paste some JavaScript such as this:

    • https://wincent.dev/javascripts/ajax.max.js

    Into the web-app version of the compiler at:

    • http://closure-compiler.appspot.com/

    Then compilation works fine and no errors or warnings are emitted. Same if I paste in the URL to the web-app instead of pasting in the source directly.

    But if I try compiling the same file using the local compiler.jar, it bails thusly:

    $ java -jar compiler.jar --js=public/javascripts/ajax.max.js  --js_output_file=public/javascripts/ajax.min.js
    {SyntheticVarsDeclar}: ERROR - Variable $ first declared in {SyntheticVarsDeclar}
    
    1 error(s), 0 warning(s)

    And the output file is 0 bytes in size.

    Would be interesting to know what the cause of the discrepancy is.

  2. Greg Hurrell 2009-11-09T13:18:20Z

    Ticket opened here:

    • http://code.google.com/p/closure-compiler/issues/detail?id=22
  3. Greg Hurrell 2009-11-12T17:41:23Z

    Upstream bug fixed and have made the switch here. Will mark as closed.

  4. Greg Hurrell 2009-11-12T17:41:30Z

    Status changed:

    • From: new
    • To: closed
Add a comment

Comments are now closed for this issue.

  • contact
  • legal

Menu

  • Blog
  • Wiki
  • Issues
  • Snippets