<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: yangzh991</title>
    <description>The latest articles on DEV Community by yangzh991 (@yangzh991).</description>
    <link>https://dev.to/yangzh991</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3841710%2F29520b03-7074-4a2f-9dd6-b18a744bbd65.png</url>
      <title>DEV Community: yangzh991</title>
      <link>https://dev.to/yangzh991</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yangzh991"/>
    <language>en</language>
    <item>
      <title>The cursorrules and CLAUDE.md setup I use for every AI product I build</title>
      <dc:creator>yangzh991</dc:creator>
      <pubDate>Thu, 26 Mar 2026 11:27:21 +0000</pubDate>
      <link>https://dev.to/yangzh991/the-cursorrules-and-claudemd-setup-i-use-for-every-ai-product-i-build-163e</link>
      <guid>https://dev.to/yangzh991/the-cursorrules-and-claudemd-setup-i-use-for-every-ai-product-i-build-163e</guid>
      <description>&lt;p&gt;Every time I start a new AI product, I used to spend the first hour&lt;br&gt;
doing the same thing: setting up Cursor rules, writing CLAUDE.md,&lt;br&gt;&lt;br&gt;
configuring the agent behavior.                                                                                                     &lt;/p&gt;

&lt;p&gt;Then I stopped doing that.                                                                                                          &lt;/p&gt;

&lt;p&gt;## What I use now                                                                                                                   &lt;/p&gt;

&lt;p&gt;Three files. That's it.                                                                                                             &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;.cursorrules&lt;/strong&gt; — tells Cursor how to handle React + TypeScript in AI products specifically. Component patterns, streaming state conventions, how to structure tool-call UI.                                                                                         &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CLAUDE.md&lt;/strong&gt; — project context for Claude Code. What the app does, tech stack, file structure, what NOT to touch. Claude reads this before every session.                                                                                                               &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AGENTS.md&lt;/strong&gt; — defines agent roles and boundaries when you're                      running multi-agent workflows. Which agent owns which part of the&lt;br&gt;
codebase.                                                                                                                           &lt;/p&gt;

&lt;p&gt;## Why this matters                                                                                                                 &lt;/p&gt;

&lt;p&gt;Without these files, every AI coding session starts cold. The model doesn't know your conventions, rewrites things you already decided, asks questions you've answered before.                                                                                              &lt;/p&gt;

&lt;p&gt;With them, you drop into any session and the context is already there.                                                              &lt;/p&gt;

&lt;p&gt;## What's in the cursorrules specifically                                                                                           &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;React + TypeScript strict mode conventions
&lt;/li&gt;
&lt;li&gt;AI component patterns (streaming, tool-calls, loading states)&lt;/li&gt;
&lt;li&gt;Tailwind class ordering
&lt;/li&gt;
&lt;li&gt;File naming and folder structure&lt;/li&gt;
&lt;li&gt;What to avoid (no useEffect for data fetching, no any types)
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;## How to use it&lt;/p&gt;

&lt;p&gt;Drop the three files into your project root. Adjust the stack&lt;br&gt;&lt;br&gt;
  references to match your setup. Done.&lt;/p&gt;

&lt;p&gt;I packaged mine up here if you want to skip writing from scratch:&lt;br&gt;&lt;br&gt;
  &lt;a href="https://payhip.com/b/BVfGI" rel="noopener noreferrer"&gt;https://payhip.com/b/BVfGI&lt;/a&gt; ($19)&lt;/p&gt;

&lt;p&gt;Or just use this as a starting point and build your own.                                                                            &lt;/p&gt;

&lt;p&gt;What does your CLAUDE.md look like? Curious what context other&lt;br&gt;&lt;br&gt;
  people include. &lt;/p&gt;

</description>
      <category>cursor</category>
      <category>ai</category>
      <category>typescript</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Why I built a React component library specifically for AI products</title>
      <dc:creator>yangzh991</dc:creator>
      <pubDate>Thu, 26 Mar 2026 10:50:45 +0000</pubDate>
      <link>https://dev.to/yangzh991/why-i-built-a-react-component-library-specifically-for-ai-products-3log</link>
      <guid>https://dev.to/yangzh991/why-i-built-a-react-component-library-specifically-for-ai-products-3log</guid>
      <description>&lt;p&gt;Last year I was building an AI chat interface. I needed a component that shows streaming text with a blinking cursor, one that displays tool calls in progress, and another that tracks token usage in real time.&lt;/p&gt;

&lt;p&gt;I opened npm. Nothing.&lt;/p&gt;

&lt;p&gt;Every UI library I found — shadcn, MUI, Chakra — was built for traditional apps. Forms, tables, dashboards. Great libraries. Wrong problem.&lt;/p&gt;

&lt;p&gt;So I built Aura UI.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F74n8wma94k6eu3281m6q.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F74n8wma94k6eu3281m6q.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Most AI products need the same 9 things that no library provides:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;MessageBubble&lt;/strong&gt; — chat layout with role-based styling&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;StreamingIndicator&lt;/strong&gt; — animated states (thinking / streaming / done)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ToolCallCard&lt;/strong&gt; — shows what the agent is doing in real time&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ParameterSlider&lt;/strong&gt; — temperature, top-p controls with live preview&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;CitationBlock&lt;/strong&gt; — source references with hover expand&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;TokenCounter&lt;/strong&gt; — live usage with limit warnings&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;CodeBlock&lt;/strong&gt; — syntax highlight + copy, optimized for LLM output&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;PromptEditor&lt;/strong&gt; — textarea with token count + template variables&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ModelSelector&lt;/strong&gt; — provider/model picker with context window info&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6idf2976e684r16g4vi0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6idf2976e684r16g4vi0.png" alt=" " width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Plus 10 base components (Button, Input, Modal, etc.) that match the same design language.&lt;/p&gt;

&lt;h2&gt;
  
  
  The streaming state machine
&lt;/h2&gt;

&lt;p&gt;The part that took longest: streaming has 4 distinct states — Thinking → Streaming → Complete → Error. Each needs its own visual language. Most teams hack this with booleans. Aura UI ships it solved.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnuorsp14er1m7x7wsbtt.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnuorsp14er1m7x7wsbtt.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Tech
&lt;/h2&gt;

&lt;p&gt;React + TypeScript + Tailwind CSS. Dark/light mode.&lt;br&gt;
Zero runtime dependencies beyond React itself.&lt;br&gt;
Source code included — no black box.&lt;/p&gt;

&lt;h2&gt;
  
  
  Get it
&lt;/h2&gt;

&lt;p&gt;Live demo → &lt;a href="https://aura-ui-mocha.vercel.app" rel="noopener noreferrer"&gt;https://aura-ui-mocha.vercel.app&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;What you get:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;19 components (full source, not a compiled black box)&lt;/li&gt;
&lt;li&gt;TypeScript types + Tailwind config included&lt;/li&gt;
&lt;li&gt;Dark/light mode out of the box&lt;/li&gt;
&lt;li&gt;Free updates&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Early bird: $49 → $99 after 200 seats&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If this saves you a week of work on your next AI product:&lt;br&gt;
→ &lt;a href="https://payhip.com/b/z9Hjr" rel="noopener noreferrer"&gt;https://payhip.com/b/z9Hjr&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Happy to answer questions below — especially if there's a component&lt;br&gt;
you need that's not on the list.&lt;/p&gt;

</description>
      <category>react</category>
      <category>ai</category>
      <category>typescript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>The .cursorrules + CLAUDE.md + AGENTS.md setup that stopped my AI agent from ignoring me</title>
      <dc:creator>yangzh991</dc:creator>
      <pubDate>Tue, 24 Mar 2026 13:18:59 +0000</pubDate>
      <link>https://dev.to/yangzh991/the-cursorrules-claudemd-agentsmd-setup-that-stopped-my-ai-agent-from-ignoring-me-20pb</link>
      <guid>https://dev.to/yangzh991/the-cursorrules-claudemd-agentsmd-setup-that-stopped-my-ai-agent-from-ignoring-me-20pb</guid>
      <description>&lt;p&gt;Every session, the same problem.                          &lt;/p&gt;

&lt;p&gt;I open Cursor, start a task, and within minutes the AI is:                                                                                                      &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Generating components that already exist
&lt;/li&gt;
&lt;li&gt;Using patterns we explicitly don't use
&lt;/li&gt;
&lt;li&gt;Renaming things I didn't ask it to rename
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Sound familiar?                                                                                                                                                 &lt;/p&gt;

&lt;p&gt;The fix isn't a better prompt. It's better rules files.                                                                                                         &lt;/p&gt;

&lt;p&gt;Here's the setup I now use on every project:                                                                                                                    &lt;/p&gt;

&lt;p&gt;## .cursorrules                                                                                                                                                 &lt;/p&gt;

&lt;p&gt;Tells Cursor how to write code in this repo. Mine covers:                                                                                                       &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;TypeScript strict patterns (no &lt;code&gt;any&lt;/code&gt;, discriminated unions for AI states)&lt;/li&gt;
&lt;li&gt;Streaming hook conventions with proper abort cleanup
&lt;/li&gt;
&lt;li&gt;Folder structure enforcement
&lt;/li&gt;
&lt;li&gt;Security rules (no API keys in state, sanitize AI output)
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;## CLAUDE.md                                              &lt;/p&gt;

&lt;p&gt;Loaded at the start of every Claude Code session. Includes:                                                                                                     &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tech stack&lt;/li&gt;
&lt;li&gt;Current sprint goals
&lt;/li&gt;
&lt;li&gt;Business rules the AI must never violate
&lt;/li&gt;
&lt;li&gt;What it should always/never do&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;## AGENTS.md                                              &lt;/p&gt;

&lt;p&gt;The strictest file. Prevents agents from:                 &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Renaming files without permission&lt;/li&gt;
&lt;li&gt;Deleting code without explaining it first
&lt;/li&gt;
&lt;li&gt;Adding dependencies without listing them&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;I packaged all three as a starter pack with fill-in-the-blank&lt;br&gt;&lt;br&gt;
  templates for React + TypeScript + AI product projects.&lt;/p&gt;

&lt;p&gt;If you want to grab it: &lt;a href="https://payhip.com/b/BVfGI" rel="noopener noreferrer"&gt;https://payhip.com/b/BVfGI&lt;/a&gt; ($19)&lt;br&gt;
  If you want the full setup pre-built and ready to drop in:&lt;br&gt;&lt;br&gt;
  &lt;a href="https://payhip.com/b/BVfGI" rel="noopener noreferrer"&gt;https://payhip.com/b/BVfGI&lt;/a&gt; ($19)                                                                                                        &lt;/p&gt;

&lt;p&gt;Or drop a comment and I'll paste the .cursorrules here for free. &lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
