Skip to content

Claude Code Prompts Textbook

A free, self-paced textbook in 7 chapters. Read a chapter, then drill it with the 100 companion flashcards using spaced repetition.

7 chapters · 100 cards · Updated

Chapters

  1. 1Getting Started with Claude Code

    Claude Code is Anthropic's official AI-powered command-line tool designed to help developers write, edit, debug, and understand code directly from the terminal. To begin, you simpl...

  2. 2Project Context and Configuration

    Beyond the working directory, the most effective way to give Claude Code persistent project knowledge is through a `CLAUDE.md` file placed in the project root. Claude Code automati...

  3. 3Reading, Searching, and Understanding Code

    Before changing anything, it often pays to ask Claude to read the existing code. A simple "Read [filename] and explain what it does" or just "Read [filename]" gets Claude oriented,...

  4. 4Writing, Editing, and Refactoring Code

    When you want Claude to change existing code, specificity is the most important ingredient. To refactor, state the goal explicitly: "Refactor this function to use async/await inste...

  5. 5Testing, Debugging, and Code Review

    Claude Code is a capable test author when given clear scope. A good starting prompt is "Write unit tests for [function/file] covering edge cases including null inputs, empty arrays...

  6. 6APIs, Data, and Infrastructure

    Claude Code can scaffold and modify the moving parts of a typical web application. For new endpoints, a complete prompt looks like "Create a [GET/POST/PUT/DELETE] endpoint at [path...

  7. 7Architecture, Documentation, and Release Workflow

    For higher-level work, the prompts shift from individual files to systems. To evaluate an existing design, ask "Review the current architecture of [system/feature] and identify any...

← Back to the Claude Code Prompts deck