How JavaScript Minification Works
AnyTool minifies JavaScript with Terser, the industry-standard engine that handles modern ECMAScript (ES2020+) syntax — whitespace/comment removal, identifier mangling, and dead-code elimination. A beautify direction uses Terser's format options to reformat minified or messy code. Terser runs in a Web Worker so large files don't block the UI, and a gzip size estimate is computed locally via CompressionStream. The engine is bundled (no runtime CDN), so code never leaves the device.
- Terser engine — modern ES2020+ minification
- Mangle, compress, and dead-code elimination
- Beautify direction for readable output
- Runs in a Web Worker; live gzip-size estimate
- Bundled, no runtime CDN; code never leaves the device
