The code you minify is usually code you're about to ship: proprietary logic, internal API endpoints, analytics or tag snippets with account IDs. Online minifiers that send your code to a server for processing hand a copy to someone else.
formatvault minifies JavaScript with terser, the same minifier Vite, webpack, and Rollup use for production builds, running entirely in your browser. Your code never leaves your machine, and you see exactly how much smaller it gets, both minified and gzipped.
terser parses your code into a syntax tree, then compresses it (removing dead code, inlining constants and small functions, simplifying expressions) and mangles local variable names down to single letters. Finally it prints the result with no unnecessary whitespace. The code is never executed.
Minification runs in a Web Worker so large files don't freeze the page. The size bar compares the original, minified, and gzipped sizes, and the diff view shows what changed. Need to go the other way? The JavaScript Formatter turns minified code back into readable form.