Blenra
Optimized for: Gemini / ChatGPT / Claude

Advanced AI Prompt for Performance Tuning Deeply Nested Radix Menus

Use this engineered prompt to drastically optimize your workflow and output.

Required Variables

  • [DOM_NODE_LIMIT]
  • [MEMOIZATION_STRATEGY]
  • [LAZY_LOADING]
radix-menu-performance-optimization.txt
Identify and fix performance bottlenecks in a large-scale Radix UI Menu system with over [DOM_NODE_LIMIT] potential nodes. Implement a [MEMOIZATION_STRATEGY] for individual menu items to prevent re-renders on hover. Utilize [LAZY_LOADING] patterns for submenus so they only mount to the DOM when their parent is hovered or focused. Compare the performance of 'portal' vs 'non-portal' rendering for deep trees. Provide a Profiler-based evidence report for the proposed optimizations.

Example Output

"The AI provides a memoized React component structure for menu items and a 'LazySubmenu' component that uses conditional rendering inside Radix's SubContent."