Composer Multi-Step Prompt
Sequential steps prevent Cursor Composer from trying to do everything at once and losing coherence. The @reference_file pattern ensures consistency with existing code.
I need to implement {{feature_name}}. Here's the plan — execute each step in order: Step 1: Create the data model / types in {{types_location}} Step 2: Build the API route at {{api_path}} with GET and POST handlers Step 3: Create the UI component at {{component_path}} Step 4: Wire up the component to the API with proper loading/error states Step 5: Add form validation using {{validation_library}} For each step: - Follow existing patterns in the codebase (check similar files first) - Use @{{reference_file}} as a reference for style and structure - Do NOT modify any files outside the ones listed above After all steps, list any environment variables or dependencies I need to add.
Variables to customize
Why this prompt works
Sequential steps prevent Cursor Composer from trying to do everything at once and losing coherence. The @reference_file pattern ensures consistency with existing code.
Save this prompt to your library
Organize, version, and access your best prompts across ChatGPT, Claude, and Cursor.
Related prompts
Get thorough code reviews with actionable feedback tailored to your language, framework, and standards.
Context-Aware Code CompletionProviding the surrounding code and project context lets the model match existing patterns exactly. The constraint against modifying existing code prevents unwanted side effects.
Inline Code SuggestionConstraining suggestions to match existing style and scope produces insertions that feel native to the codebase. The 'no explanation' rule mimics real inline completion behavior.
Code ExplanationThe audience level parameter adjusts complexity automatically. Requiring a usage example ensures the explanation is practical, not just theoretical.