next.js
553b84b6 - Add expert AI prompts for boundary issue resolution

Commit
158 days ago
Add expert AI prompts for boundary issue resolution Created context-aware prompts that developers can copy-paste to AI assistants for evaluation and fix recommendations. **Features:** - Generate separate prompts for each heuristic detection type - Prompts include specific file paths, prop names, and values - Two-section format: EVALUATE and FIX **EVALUATE Section:** - Ask AI to verify if heuristic is correct - Include specific detection context (prop paths, values, patterns) - Guide AI to consider security implications **FIX Section:** - Provide 4 opinionated fix options - Reference exact code locations and prop names - Include code examples with actual boundary details - Options: Server Component, Filter Data, Taint API, Restructure **Sensitive Data Prompt:** - Shows which props matched which patterns - Includes full member chains (e.g., config.credentials.password) - Suggests React taint API for runtime protection **Non-Serializable Prompt:** - Lists function props that cannot serialize - Explains Server Actions as alternative - Provides client-side event handler pattern **Implementation:** - Created expert-prompts.ts module - Integrated into formatBoundaryAnalysis() - One prompt per detection category per boundary - Prompts use template interpolation for specific details 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Author
Parents
Loading