PROMPT VAULT
Prompts & Skills Vault
14 entries and growingReady-to-use prompts and UI components for AI-powered projects. Copy, preview, and remix.
# Refactoring without breaking things Refactoring means changing structure without changing behavior. If you're also changing what the code does, that's not a refactor -- do it as a separate, clearly labeled change so a regression can be traced to the right commit. ## Step 1: Confirm there's a safety net Before touching the code, check whether it has tests that would catch a behavior change. - **If yes**: run them now, before any change, and confirm they pass. This is your baseline. - **If no**: write characterization tests first -- tests that capture the *current* actual behavior (includi
SkillAdvanced
Safe Refactoring
claude
# Commit messages and PR descriptions
## Commit message format
Use Conventional Commits:
```
<type>(<scope>): <short summary, imperative mood, no period>
<body: why this change, not what -- the diff already shows what>
```
**Types**: `feat` (new capability), `fix` (bug fix), `refactor` (no behavior change), `perf`, `docs`, `test`, `build`, `ci`, `chore` (tooling/deps, no source change), `revert`.
**Scope**: the module/area affected, lowercase, e.g. `auth`, `api`, `checkout`. Omit if the change is repo-wide.
**Summary line**: imperative mood ("add", not "added"/"adds"), under ~50 charactSkillBeginner
Commit Messages & PR Descriptions
claude
# Code review Review the diff or files in front of you against the checklist below. Report findings ranked by severity -- most severe first -- not in the order you found them. ## Checklist **Correctness** - Does the logic handle the stated requirement, including edge cases (empty input, zero, negative numbers, null/undefined, empty arrays)? - Off-by-one errors in loops, slices, or pagination? - Are async operations awaited? Is there a race condition between two operations that assume ordering? **Security** - User input reaching a SQL query, shell command, or HTML output without sanitizatio
SkillIntermediate
Code Review Checklist
claude
# Systematic debugging Don't propose a fix before completing the steps below. A fix for the wrong cause either does nothing or introduces a new bug that looks unrelated. Copy this checklist and track progress: ``` Debugging Progress: - [ ] Step 1: Reproduce - [ ] Step 2: Isolate - [ ] Step 3: Form a hypothesis - [ ] Step 4: Test the hypothesis - [ ] Step 5: Fix and verify ``` **Step 1: Reproduce** Get a reliable way to trigger the bug -- exact input, exact steps, exact environment. If you can't reproduce it, you can't verify a fix worked; find a way before proceeding, even if it means add
SkillIntermediate
Systematic Debugging
claude
# README generation Don't start from a template. Inspect the project first, then write only the sections that apply to what you actually find. ## Step 1: Inspect before writing - Read the manifest file for the language in use (`package.json`, `pyproject.toml`, `Cargo.toml`, `go.mod`, etc.) -- get the real name, description, dependencies, and scripts. - Check for a working entry point (`main.py`, `src/index.ts`, `cmd/main.go`) to understand what the project actually does and how it's run. - List existing scripts/commands (`npm run`, `Makefile` targets, `poetry run`) -- these become your docu
SkillBeginner
README Generator
claude
# Writing meaningful tests
A test that can't fail isn't testing anything. Before writing each test, state what specific bug it would catch if the implementation were wrong.
## Step 1: Identify what to test
For the function/module in front of you, list:
- **Happy path**: the typical, expected input and output.
- **Edge cases**: empty input (`""`, `[]`, `{}`), zero, negative numbers, the boundary of a range (exactly min, exactly max, one past each), null/undefined, very large input.
- **Failure modes**: what should happen when the input is invalid -- does it throw, return an error value, or sSkillIntermediate
Writing Meaningful Tests
claude
Live
ComponentBeginner
Component: Animated Counter
claude
Live
HeroBeginner
Hero Section with Gradient CTA
claudegpt
Live
ComponentIntermediate
Component: Toast Notification System
claudegpt
Live
LandingIntermediate
Landing Page with Feature Grid
claudegemini
Live
DashboardAdvanced
Dashboard Analytics Cards
gptclaude
Live
DashboardIntermediate
Dashboard Data Table with Filters
gpt
Live
AgentAdvanced
AI Agent Configuration Panel
claude
Live
ChatbotBeginner
Chatbot Message Bubble UI
claudegptgemini