generated from Paul.Kim/tpl-superclaude
2.3 KiB
2.3 KiB
End-to-End Feature Implementation Guide
Context
- When implementing new end-to-end features
- When planning feature development workflow
- When ensuring consistent architecture
Requirements
- Follow the implementation steps in order
- Use the appropriate standards for each step
- Ensure consistency across all implementation layers
- Test each phase before moving to the next
Implementation Steps
-
Schema Definition → Use rule @.cursor/rules/2101-schema-prisma.mdc
- Define Prisma schema with standard fields
- Add proper relations and indexes
- Use correct field types and constraints
- Follow naming conventions
-
Router Implementation → Use rule @.cursor/rules/2102-router.mdc
- Create protected tRPC router
- Add input validation with Zod
- Implement cursor-based pagination
- Handle security and responses
-
React Query Integration → Use rule @.cursor/rules/2103-trpc-react-query.mdc
- Set up queries with queryOptions
- Handle loading states
- Implement optimistic updates
- Manage cache invalidation
-
CRUD Implementation → Use rule @.cursor/rules/2105-crud.mdc
- Follow phased implementation approach
- Start with Create & Read operations
- Add Update & Delete operations
- Implement advanced features last
-
Authentication → Use rule @.cursor/rules/2106-auth.mdc
- Use protectedProcedure for routes
- Add session checks in components
- Implement auth guards
- Handle unauthorized states