Claude Code has a huge range of slash commands for various functionality.
https://code.claude.com/docs/en/slash-commands
Custom Slash Commands
You can create custom ones as well, which many devs find valuable.
https://code.claude.com/docs/en/slash-commands#custom-slash-commands
Creating a Custom Slash Command
In your project folder, create a markdown file with your slash command's name.
e.g. if you're creating a slash command named /translate -
.claude
commands
translate.mdIn that Markdown file, create whatever prompt you find useful.
Arguments
When you invoke the command, e.g.;
/translate the pink bunny likes flamingos You can inject the full set of arguments into your prompt using $ARGUMENTS as follows;
Translate "$ARGUMENTS" to German. You can also inject specific arguments by position.
Personal Favorites
/append
When interacting with Claude, it will often respond with research results and a series of possible implementation approaches with pros and cons. I typically want to save these for future feature evolution - take the MVP route now, but revisit some of those other more complex strategies later.
Claude code ( the VS Code extension ) does not support direct copy-as-markdown from the agent window, so I use this as a generally effective workaround.
Append your last response here, as is, markdown with no changes to the file-
$ARGUMENTS
After completing, respond with "APPENDED TO FILE." /discuss
Using Claude there are often situations where I was to discuss a solution approach, implementation details, or review a bug before Claude makes any changes.
This is gold.
DISCUSS ONLY
$ARGUMENTSPro-Tips
If you're using Claude code with VS code, and modify your slash commands, Claude will not see those changes until you either;
- Start a new Claude session
- Reload the current session
