🧼 CodePolish
CodePolish is a Visual Studio Code extension that lets you beautify and minify HTML, CSS, and JavaScript code with ease. Whether you want clean, readable code or compact, production-ready output — CodePolish handles it in one click.

✨ Features
- ✅ Beautify with
Alt + Shift + B
- ✅ Minify via right-click context menu
- ✅ Supports:
- 🟧 HTML
- 🟦 CSS
- 🟨 JavaScript
- ✅ Auto-detects language and applies correct formatter
- ✅ Works offline after setup
- ✅ Lightweight and fast
🧪 Language Support
Language |
Beautifier |
Minifier |
HTML |
js-beautify |
terser |
CSS |
js-beautify |
clean-css |
JavaScript |
js-beautify |
terser |
🚀 Installation
From VS Code Marketplace
- Launch VS Code
- Go to Extensions (
Ctrl + Shift + X
)
- Search for CodePolish
- Click Install
From Source (GitHub)
git clone https://github.com/bharat0316-a/codepolish.git
cd codepolish
npm install
npm run compile
Then press F5
to launch a development window.
⚙️ Usage
🧼 Beautify
- Shortcut: Select the code →
Alt + Shift + B
- Or: Right-click in editor → Beautify Code
📦 Minify
- Select the code -> Right-click in editor → Minify Code
You can also run both from the command palette (Ctrl + Shift + P
→ search "CodePolish").
🧠 Extension Commands
Command |
Description |
codepolish.beautify |
Beautifies the current file |
codepolish.minify |
Minifies the current file |
📁 Project Structure
codepolish/
├── src/
│ ├── extension.ts # VS Code entry point
│ └── formatter.ts # Format logic per language
├── out/ # Compiled output
├── package.json # Metadata and config
├── README.md # This file
└── icon.jpg # Extension icon
🧑💻 Development
npm install # Install dependencies
npm run compile # Compile TypeScript
npm run watch # Watch & auto-recompile
- Press
F5
in VS Code to run the extension in a development window.
🖼 Preview
📸 GIFs and screenshots coming soon!
Want to contribute one? Open a PR or issue
📝 License
CodePolish is open-source under the MIT License.
🤝 Contributing
Contributions, suggestions, and bug reports are welcome!
fork → clone → branch → commit → push → PR
Open an issue or submit a pull request to help improve the project.
👤 Author
Developed by Bharat
📂 GitHub: github.com/bharat0316-a/codepolish
🧼 Clean code. Always. Everywhere — for HTML, CSS, and JS.