Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Collapse All CodeNew to Visual Studio Code? Get it now.
Collapse All Code

Collapse All Code

Vandan Patel

|
176 installs
| (1) | Free
One-click button to collapse all functions and blocks in large files.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

📦 Collapse All Code (One-Click Fold Extension)

Effortlessly collapse all functions and foldable blocks in your file with a single click. Perfect for large Next.js, React, and TypeScript files.

✨ Features

  • 🔘 Adds a custom button to the editor title bar
  • 🧠 Collapses all foldable ranges (functions, objects, blocks)
  • 💻 Works with TypeScript, JavaScript, and more
  • 🎯 Designed for large codebases
  • 🎨 Dark and light mode SVG icons

📷 Screenshot

Demo

🚀 Usage

  • Click the 🡇 icon in the top-right of your editor
  • Or run the Collapse All Code command from the Command Palette (Cmd+Shift+P)
  • (Optional) Use keyboard shortcut: Ctrl+Alt+K

🔧 Requirements

None – it just works!

💬 Feedback

Found a bug or want a new feature? Open an issue

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft