
August 29, 2024
Code Like a PM: Using PRDs to Supercharge AI Coding in Cursor
When most devs talk about AI-assisted coding, they focus on prompts. But the real magic happens before you ever touch the keyboard.
With Goru, our goal-setting app built in React Native, the first thing we did wasn’t code—it was write a PRD. Then we handed it off to Cursor and asked the AI to generate a full development plan.
What we got back was more than helpful—it became our blueprint for a 6-week build.
Step 1: Writing the PRD
Before we even opened Cursor, we wrote a lightweight but detailed Product Requirements Document. It outlined everything from the user journey to the technical architecture.
We broke the app downinto clear experiences:
- A chat-based SMART goal creation flow
- AI-driven milestone scheduling
- A weekly timeline to visualize progress
- A journaling system with streaks and reflection
- A stats dashboard powered by AI insights
Then we added tech stack decisions, database schema, key UX flows, and UI principles—like keeping things minimal, clean, and energy-aware.
Step 2: Prompting Cursor with the PRD
Here’s where the magic kicked in.
We dropped the entire PRD into Cursor and prompted:
“Based on this spec, generate a development plan for building this app in React Native using Supabase, OpenAI, and Expo. Break it down by phases and tasks, with a week-by-week structure.”
Within seconds, Cursor gave us a full development outline:
The AI-Generated Development Plan (Highlights)
Phase 1: Project Setup & Infra
- Initialize Expo project with TypeScript
- Set up ESLint, Prettier, and Git
- Configure Supabase and OpenAI clients
Phase 2: Timeline UI
- Create horizontal month selector
- Build vertical weekly timeline
- Add view toggle + empty state
Phase 3: Chat-Based Goal Creation
- Build chat interface components
- Integrate OpenAI for goal analysis
- Add due date picker + busyness selector
Phase 4: Milestone Management
- Create milestone cards with CRUD actions
- Implement batch add to timeline
- Enable drag-and-drop reordering
Phase 5: Journaling & Progress
- Build journaling chat flow
- Add daily reflection logging
- Track streaks and challenges
Phase 6: Polish & Deploy
- Add loading states, error handling
- Run tests and deploy to App Store
Step 3: Letting AI Code with Context
With the dev plan in place, we could prompt Cursor in context:
“Generate a ChatInterface component for React Native Paper that supports async AI responses, suggestion buttons, and a typing indicator.”
“Scaffold the milestone schema in Supabase and write the TypeScript types.”
Each prompt was sharper, because the AI understood the project.
Iterate with the Same PRD in ChatGPT
When I wanted to switch tools—for example, to ask ChatGPT to generate a better onboarding flow or a naming convention for tables—I could reuse the same PRD. This let me:
- Stay aligned across tools
- Reuse architecture decisions
- Avoid re-explaining everything
The PRD became our single source of truth.
Bonus: Turn It Into a Living Document
As we progressed, we updated the plan:
- Checked off completed phases
- Broke large features into GitHub issues
- Used the schema to seed database migrations
- Linked UI components back to Figma designs
It wasn’t static—it was our AI-enabled dev ops system.
💡 Final Thoughts: PRD + AI = Velocity
The biggest myth about AI coding is that it removes the need for planning. The opposite is true.
AI amplifies your thinking—but it can’t think for you. That’s why writing a PRD, even if it’s scrappy, sets you up to prompt smarter, build faster, and stay aligned with your product vision.
Cursor didn’t just write our code.
It followed our blueprint.
And that blueprint? That came from thinking like a PM first.
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. Nunc ut sem vitae risus tristique posuere.