Uglify JS

Use this skill when the user wants to minify JavaScript files for production — reduce bundle size, rename variables, remove dead code, and generate source maps.

javimosch Updated 57 repo stars

File contents

UglifyJS Plugin

UglifyJS minifies and compresses JavaScript files. Removes whitespace, shortens variable names, eliminates dead code, and optimizes expressions for smaller production bundles.

Commands

  • uglify-js _ _ <args> — Passthrough

Usage Examples

  • "minify app.js to app.min.js"
  • "minify with source map support"
  • "compress multiple JS files into one"
  • "beautify/minified code for debugging"

Installation

npm install -g uglify-js

Key Features

  • Whitespace removal and variable mangling
  • Dead code elimination
  • Expression and statement optimization
  • Source map generation
  • Multiple input concatenation
  • Beautify output option
  • Compression level control
  • CLI batch processing

javimosch/supercli commit cb72baea47

Frequently asked questions

npx get-skill add javimosch/uglify-js