UglifyJS is a JavaScript compressor/minifier written in JavaScript. It also contains tools that allow one to automate working with JavaScript code. A parser which produces an abstract syntax tree (AST) from JavaScript code. A code generator which outputs JavaScript code from an AST, also providing the option to get a source map. A compressor (optimizer). it uses the transformer API to optimize an AST into a smaller one. A mangler, reduce names of local variables to (usually) single-letters. A scope analyzer, which is a tool that augments the AST with information about where variables are defined/referenced etc. A tree walker, a simple API allowing you to do something on every node in the AST. A tree transformer, another API intended to transform the tree. All the above utilities and APIs are defined in ~6500 lines of code (except for the effective generation of the source-map, which is handled by the source-map module). Compared to alternatives, UglifyJS is pretty small.

Features

  • Supports JavaScript and most language features in ECMAScript
  • For more exotic parts of ECMAScript, process your source file with transpilers like Babel
  • UglifyJS can take multiple input files
  • It's recommended that you pass the input files first, then pass the options
  • UglifyJS will parse input files in sequence and apply any compression options
  • If no input file is specified, UglifyJS will read from STDIN

Project Samples

Project Activity

See All Activity >

Categories

File Compression

License

BSD License

Follow UglifyJS 3

UglifyJS 3 Web Site

Other Useful Business Software
$300 Free Credits for Your Google Cloud Projects Icon
$300 Free Credits for Your Google Cloud Projects

Start building on Google Cloud with $300 in free credits. No commitment, no credit card required until you're ready to scale.

Launch your next project with $300 in free Google Cloud credits—no strings attached. Test, build, and deploy without risk. Use your credits across the entire Google Cloud platform to find what works best for your needs. After your credits are used, continue with always-free tier services. Only pay when you're ready to scale. Sign up in minutes and start exploring.
Start Free Trial
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of UglifyJS 3!

Additional Project Details

Programming Language

JavaScript

Related Categories

JavaScript File Compression Software

Registered

2021-05-19