Comment Style Converter
Translate //, #, --, ;, %, /* */, and <!-- --> comments between languages while preserving indentation.
Converted
</>Use this tool programmaticallycurl · JavaScript · MCP
Same tool, callable from any HTTP client or from Claude (via MCP). Anonymous: 100 req/day per IP. Sign up for 1,000 req/day.
curl
curl https://api.b-e-a-d.com/tools/comment-style-converter/run \
-H "Content-Type: application/json" \
-d '{
"source": "a",
"from": "slash-slash",
"stripOnly": false
}'JavaScript (fetch)
const res = await fetch("https://api.b-e-a-d.com/tools/comment-style-converter/run", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"source": "a",
"from": "slash-slash",
"stripOnly": false
}),
});
const data = await res.json();
console.log(data.result);MCP (Claude Desktop / Claude Code)
# In Claude Desktop / Claude Code, add to your MCP config:
{
"mcpServers": {
"bead": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://mcp.b-e-a-d.com"]
}
}
}
# Then ask Claude to call:
mcp__bead__bead_comment_style_converterFull reference: developer docs · OpenAPI spec
Why
Porting code or documentation between languages often leaves a trail of orphaned // in Python or # in JavaScript. This tool strips the source comment prefix and re-wraps the lines in the target style — preserving indentation and blank lines.
Supported styles
- Line:
//,#,--,;,% - Block:
/* … */,<!-- … -->,{- … -},(* … *)
You might also like
- Tabs ↔ Spaces ConverterConvert between tabs and spaces with adjustable width — leading-only or all whitespace.
- ANSI Escape StripperRemove ANSI color codes and terminal control sequences from CI logs or terminal captures.
- Diff CheckerCompare two pieces of text side-by-side with line- and word-level highlighting.
- Email Address List ParserParse RFC 5322 address lists with display names, quoted strings, comments, and validation.