premortem / CO-STAR-UI-CREATOR
Cursor rule2 starsChanged 5 months agoApache-2.0View on GitHub
A structured prompt system for building React/Next.js UIs with modern component registries (shadcn, Magic UI, Aceternity, etc.). Use this guide to set up and use the CO-STAR prompts in your IDE. Mac / Linux (Bash): Windows (PowerShell): What this does: Put only ui.md in commands/. Put the rest of the files in rules/CO-STAR-UI-CREATOR/. When you invoke /ui or /ui.md, it automatically uses and redirects to the files in rules/. Paths: - Command (invoke): your-project/.cursor/commands/ui.md - Resources (referenced by ui.md): your-project/.cursor/rules/CO-STAR-UI-CREATOR/
- Deletes or force-pushes
Where files are headingNew Cursor rule files have more rules about planning and tracking tasks, and fewer about code style.
Of the Cursor rule files we read, the 4,183 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository168 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .cursor/rules/CO-STAR-UI-CREATOR/AGENT.mdcCursor rule
- .cursor/rules/CO-STAR-UI-CREATOR/CO-STAR-CREATOR.mdCursor rule
- .cursor/rules/CO-STAR-UI-CREATOR/CO-STAR-PROMPT.mdCursor rule
- .cursor/rules/CO-STAR-UI-CREATOR/ui.mdCursor rule
- 401-403-bypass-techniquesSkill
- active-directory-acl-abuseSkill
- active-directory-certificate-servicesSkill
- active-directory-kerberos-attacksSkill
- agent-browserSkill
- ai-ml-securitySkill
- ai-seoSkill
- android-pentesting-tricksSkill
- anti-debugging-techniquesSkill
- api-auth-and-jwt-abuseSkill
- api-authorization-and-bolaSkill
- api-recon-and-docsSkill
- api-secSkill
- arbitrary-write-to-rceSkill
- arize-adminSkill
- arize-ai-provider-integrationSkill
- arize-annotationSkill
- arize-compliance-auditSkill
- arize-datasetSkill
- arize-evaluatorSkill
- arize-experimentSkill
- arize-instrumentationSkill
- arize-linkSkill
- arize-prompt-optimizationSkill
- arize-promptsSkill
- arize-traceSkill
- authbypass-authentication-flawsSkill
- auth-secSkill
- binary-protection-bypassSkill
- browser-exploitation-v8Skill
- building-nango-functions-locallySkill
- building-nango-functions-remotelySkill
- building-nango-functionsSkill
- business-logic-vulnerabilitiesSkill
- business-logic-vulnSkill
- classical-cipher-analysisSkill
- clickjackingSkill
- cmdi-command-injectionSkill
- code-obfuscation-deobfuscationSkill
- compliance-checkSkill
- compliance-trackingSkill
- container-escape-techniquesSkill
- core-engineeringSkill
- cors-cross-origin-misconfigurationSkill
- crlf-injectionSkill
- csp-bypass-advancedSkill
- csrf-cross-site-request-forgerySkill
- csv-formula-injectionSkill
- d3-visualizationSkill
- dangling-markup-injectionSkill
- defi-attack-patternsSkill
- dependency-confusionSkill
- deserialization-insecureSkill
- dns-rebinding-attacksSkill
- documentation-writerSkill
- The first 60 shown.
The file
We split this README.md into the rules it gives an agent
10 rules. About 0 are common, 2 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 64
Put only ui.md in commands/.
- Very specific: line 85
How it works: When you type /ui or /ui.md, the command runs ui.md.
- Very specific: line 108
Create .cursor in your project root if it doesn't exist.
- Very specific: line 109
Put ui.md in .cursor/commands/ui.md.
- Very specific: line 110
Put the rest (AGENT.mdc, CO-STAR-PROMPT.md, CO-STAR-CREATOR.md, README.md) in .cursor/rules/CO-STAR-UI-CREATOR/.
- Very specific: line 117
If your IDE doesn't support .cursor rules or commands:
- Very specific: line 123
Use CO-STAR-CREATOR.md when you want to create a custom CO STAR prompt.
- Distinctive: line 154
Use the resulting prompt as a custom system prompt or reference in your IDE.
- Distinctive: line 161
Start a new chat.
- Very specific: line 165
If it doesn’t, reference the prompt directly: @rules/CO-STAR-UI-CREATOR/CO-STAR-PROMPT.md or paste the relevant section into the chat.
≈ “Common” is an estimate: at least 1 in 5 of the 6,668 Cursor rule files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
CO-STAR UI Creator — Setup & Usage Guide
A structured prompt system for building React/Next.js UIs with modern component registries (shadcn, Magic UI, Aceternity, etc.). Use this guide to set up and use the CO-STAR prompts in your IDE.
Plug & play — copy, paste, go
Just get the folder (fastest & simplest)
- Open your terminal (Bash or PowerShell) inside your project folder (where you want
.cursor/to live). - Copy and paste one block below and run it.
Mac / Linux (Bash):
# 1. Download only that specific folder
git clone --depth 1 --filter=blob:none --sparse https://github.com/JustineDevs/Public-Github-Repo.git
cd Public-Github-Repo
git sparse-checkout set "AI Development/.cursor/commands/ui-template/CO-STAR-UI-CREATOR"
# 2. Move files to your project and clean up
mkdir -p ../.cursor/commands ../.cursor/rules
cp "AI Development/.cursor/commands/ui-template/CO-STAR-UI-CREATOR/ui.md" "../.cursor/commands/"
cp -r "AI Development/.cursor/commands/ui-template/CO-STAR-UI-CREATOR" "../.cursor/rules/"
cd .. && rm -rf Public-Github-RepoWindows (PowerShell):
# 1. Download only that specific folder
git clone --depth 1 --filter=blob:none --sparse https://github.com/JustineDevs/Public-Github-Repo.git
cd Public-Github-Repo
git sparse-checkout set "AI Development/.cursor/commands/ui-template/CO-STAR-UI-CREATOR"
# 2. Move files to your project and clean up
New-Item -ItemType Directory -Force -Path "..\.cursor\commands", "..\.cursor\rules" | Out-Null
Copy-Item "AI Development\.cursor\commands\ui-template\CO-STAR-UI-CREATOR\ui.md" "..\.cursor\commands\"
Copy-Item -Recurse "AI Development\.cursor\commands\ui-template\CO-STAR-UI-CREATOR" "..\.cursor\rules\"
cd ..; Remove-Item -Recurse -Force Public-Github-RepoWhat this does:
- Snatched the folder — Grabs only that directory from GitHub (no full repo).
- Placed it correctly — Creates
.cursor/commandsand.cursor/rulesin your project and puts the files there. - Self-deleted — Removes the temporary
Public-Github-Repofolder so your workspace stays clean.
What's in this folder
| File | Purpose |
| ui.md | Universal command — put in commands/ only. Invoke with /ui or /ui.md; AI uses and redirects to files in rules/CO-STAR-UI-CREATOR/. |
| CO-STAR-PROMPT.md | Main development prompt — keep in rules/CO-STAR-UI-CREATOR/. Used when building or implementing UI. |
| CO-STAR-CREATOR.md | Guide for creating your own CO STAR prompt — keep in rules/CO-STAR-UI-CREATOR/. |
| AGENT.mdc | Cursor rule — keep in rules/CO-STAR-UI-CREATOR/. Tells the AI to use the prompts correctly. |
Where to put these files
Cursor (recommended layout)
Put only ui.md in commands/. Put the rest of the files in rules/CO-STAR-UI-CREATOR/. When you invoke /ui or /ui.md, it automatically uses and redirects to the files in rules/.
File tree:
your-project/
└── .cursor/
├── commands/
│ └── ui.md ← only this in commands; invoke /ui or /ui.md
└── rules/
└── CO-STAR-UI-CREATOR/
├── AGENT.mdc
├── CO-STAR-PROMPT.md
├── CO-STAR-CREATOR.md
└── README.mdPaths:
- Command (invoke):
your-project/.cursor/commands/ui.md - Resources (referenced by ui.md):
your-project/.cursor/rules/CO-STAR-UI-CREATOR/
How it works: When you type /ui or /ui.md, the command runs ui.md. The AI then uses and redirects to the prompts in rules/CO-STAR-UI-CREATOR/ (CO-STAR-PROMPT.md, CO-STAR-CREATOR.md) as defined in ui.md. No long path — everything is resolved from the command.
Alternative (all in commands): You can instead keep the full folder under commands/:
your-project/
└── .cursor/
└── commands/
└── ui-template/
└── CO-STAR-UI-CREATOR/
├── ui.md
├── AGENT.mdc
├── CO-STAR-PROMPT.md
├── CO-STAR-CREATOR.md
└── README.mdThen /ui or /ui.md still works; the prompts live next to ui.md in the same folder.
VS Code (with Cursor or similar AI)
- Create
.cursorin your project root if it doesn't exist. - Put ui.md in
.cursor/commands/ui.md. - Put the rest (AGENT.mdc, CO-STAR-PROMPT.md, CO-STAR-CREATOR.md, README.md) in
.cursor/rules/CO-STAR-UI-CREATOR/. - Same behavior:
/uior/ui.mduses and redirects to the rules folder.
Other IDEs (generic)
If your IDE doesn't support .cursor rules or commands:
- Copy the folder anywhere in your project (e.g.
docs/prompts/CO-STAR-UI-CREATOR/). - Reference the prompts manually:
- Open
CO-STAR-PROMPT.mdwhen doing UI development. - Copy its contents (or the relevant section) into your AI chat as context.
- Use
CO-STAR-CREATOR.mdwhen you want to create a custom CO STAR prompt.
- Open
- Bookmark the folder so you can quickly open and paste prompts into your AI assistant.
Invoke the command (short)
With ui.md in .cursor/commands/, use the universal command:
| You type | Result |
/ui or /ui.md | Command runs ui.md; AI automatically uses and redirects to the files in rules/CO-STAR-UI-CREATOR/ (CO-STAR-PROMPT.md or CO-STAR-CREATOR.md). Short — no long path. |
Example: type /ui or /ui.md in chat, then your request (e.g. "add a pricing section"). The AI routes to the right file in the rules folder and responds without you pasting a long path.
How to use
For UI development (building components, pages, design systems)
- Open a chat with your AI assistant in the project.
- Reference or paste CO-STAR-PROMPT.md (or
@CO-STAR-PROMPT.mdin Cursor). - Describe what you want to build (e.g. "Add a pricing section using shadcn-style components").
- The AI will follow the CO-STAR flow: discovery questions → plan → implementation.
For creating your own CO STAR prompt
- Open CO-STAR-CREATOR.md.
- Work through the sections (Context, Objective, Style, Tone, Audience, Response format).
- Fill in your product, design system, and goals.
- Use the resulting prompt as a custom system prompt or reference in your IDE.
Verifying it works (Cursor)
- Open your project in Cursor (with ui.md in
.cursor/commands/and CO-STAR-UI-CREATOR in.cursor/rules/). - Start a new chat.
- Type
/uior/ui.md, then e.g. "Help me add a hero section following the CO-STAR approach." - The AI should use ui.md, redirect to the rules folder, and follow the CO-STAR flow (discovery → plan → implementation).
If it doesn’t, reference the prompt directly: @rules/CO-STAR-UI-CREATOR/CO-STAR-PROMPT.md or paste the relevant section into the chat.
Troubleshooting
| Issue | Fix |
| AI ignores the CO-STAR flow | Explicitly @ mention CO-STAR-PROMPT.md in your message. |
| Rules not applying | Ensure AGENT.mdc has alwaysApply: true or the right glob patterns. |
| Wrong folder location | Put ui.md in .cursor/commands/ui.md; put prompts in .cursor/rules/CO-STAR-UI-CREATOR/. |
/ui or /ui.md not showing | Ensure ui.md is at .cursor/commands/ui.md so the slash command is available. |
| Using a different IDE | Copy prompts manually into your AI chat when needed. |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

