[!IMPORTANT]
🚀 rEcomment is now Official!
We have moved to the verified vkhey! namespace.
Good news: If you updated to this version, the new official extension should have been installed automatically via the Extension Pack.
What you should do:
Verify you have vkhey.recomment (v2.1.0+) installed.
Uninstall this version (ValKotlarovHoffman.recomment) to avoid duplicate renders.
Enjoy the new improved features!
View the new Official Page here
rEcomment is a powerful Visual Studio Code extension designed to make your code comments significantly more readable. Its main power lies in formatting your comments using Markdown rendering (an easy-to-read, HTML-like formatting language). Say goodbye to plain-text limitations and visualize documentation, complex math formulas, and diagrams where they belong—right next to your code.
✨ Features
- 🤖 Agent-Native (MCP): The first extension to bridge rich docs with AI. Using the Model Context Protocol, rEcomment allows agents like Antigravity, Cursor, and Copilot to "read" and understand your rendered math and charts, drastically improving reasoning accuracy while slashing token usage.
- 🎨 Pixel-Perfect Logic: Our proprietary SVG-slicing engine ensures that even the most complex LaTeX formulas and tables align perfectly with your editor's line height. It doesn't just look good; it feels like part of the code.
- 🧬 Interactive Mermaid Diagrams: Bring architecture to life. Render flowcharts, sequence diagrams, and Gantt charts directly in your source code comments—no external browser required.
- ➗ High-Fidelity LaTeX: Powered by KaTeX for lightning-fast, beautiful math rendering. Perfect for physics engines, financial models, and research-heavy codebases.
- 📝 Full Markdown Suite: Use headers, lists, bold/italic text, and code blocks to turn messy comments into readable, professional documentation without leaving your
.ts or .py files.
- ⚡ Zero-Friction Editing: Seamless auto-rendering. Click to edit raw text; move away to see the beauty. It stays out of your way until you need it.
- 🌍 Polyglot Support: Works out-of-the-box with Python, JS/TS, Rust, Go, C++, Java, Ruby, PHP, and more. If it supports comments, it supports rEcomment.
🚀 Usage
Wrap your Markdown content in <md> tags within comments:
Python
# <md>
# \# Algorithm Optimization
# This function implements the gradient descent update:
# $$ \theta_{j} := \theta_{j} - \alpha \frac{\partial}{\partial \theta_{j}} J(\theta) $$
#
# </md>
def gradient_descent(...):
...
Jupyter Cells
Nice and handy addition to support runnable cells in Antigravity using # %% [markdown] syntax. Content following this marker will be automatically rendered as a rEcomment block until the first non-comment line is encountered. (Supports noAutoExpand on the marker line).
# %% [markdown] noAutoExpand
# # Section Title
# This content will be rendered as Markdown and will NOT auto-expand lines.
# This content will be rendered as Markdown.
#
#
#
# It ends when it hits the first line of code.
x = 1
TypeScript / JavaScript
/* <md>
* ## Configuration Schema
* | Property | Type | Default |
* | :--- | :--- | :--- |
* | `enabled` | `boolean` | `true` |
* </md>
*/
const config = { ... };
🤖 AI Agent & IDE Integration (MCP)
rEcomment features a built-in Model Context Protocol (MCP) server, allowing AI agents to "see" your rendered documentation, diagrams, and architecture maps.
🌌 Antigravity / Generic VS Code
Antigravity automatically integrates with rEcomment to improve its reasoning capabilities.
- Open the rEcomment tab in the VS Code sidebar.
- Go to the Settings section.
- Click 🚀 Boost AI (Init MCP).
🖱️ Cursor IDE
To use rEcomment tools inside Cursor:
- Open the rEcomment tab and click 🚀 Boost AI (Init MCP).
- Restart Cursor completely to load the new configuration.
- Go to Cursor Settings > Tools > MCP.
- Find rEcomment in the list and toggle it to Enabled.
- Recommended: Add
rEcomment:* to the MCP Allowlist to allow the AI to use tools without manual confirmation for every call.
[!TIP]
If your IDE doesn't support automatic discovery, the "Boost AI" button will attempt to create a .cursor/mcp.json (for Cursor) or mcp_config.json (for Antigravity) with the correct paths.
⚙️ Configuration
rEcomment can be toggled via your VS Code settings:
| Setting |
Type |
Default |
Description |
recomment.enabled |
boolean |
true |
Enable or disable the rendering engine. |
recomment.autoExpand |
boolean |
false |
Automatically insert empty comment lines to ensure full rendering. You can block this for specific comments using <md noAutoExpand>. |
recomment.compactMode |
boolean |
true |
Force uniform font sizes for better code density. |
recomment.escapeSpecialCharacters |
boolean |
true |
Automatically escape special characters ($, _, *, etc.) when leaving a comment block to preserve literal meaning. |
💬 Feedback & Support
Found a bug? Have a feature request? We'd love to hear from you!
You can send feedback directly within VS Code:
- Click the Send Feedback button in the rEcomment tab.
- Use the rEcomment: Send Feedback command from the Command Palette.
- Or fill out our Online Feedback Form in your browser.
🛡️ Telemetry & Privacy
rEcomment uses a privacy-first, aggregated telemetry system to help improve the extension.
- Aggregated Metrics: We only collect high-level usage statistics.
- Privacy First: We never collect code snippets, file paths, variable names, or any sensitive information.
- Opt-out: rEcomment strictly respects your global VS Code telemetry settings. You can disable telemetry at any time via File > Preferences > Settings > Telemetry.
If this extension has helped make your code more readable, please consider leaving a review on the VS Code Marketplace. As an independent developer, your feedback helps me prioritize new features and keep the project growing!
Built with ❤️ .