P
💻DeveloppementAdvancedAll AIs

Build a virtualized list

Handle massive data lists

Paste in your AI

Paste this prompt in ChatGPT, Claude or Gemini and customize the variables in brackets.

Implement a virtualized list component in React that can render 100,000+ items without performance degradation. Use a windowing approach, calculate visible item range dynamically based on scroll position, and support variable item heights. Include scroll restoration.

Personalize this prompt with Léa

Answer 3 questions and Léa tailors the prompt to your situation.

Use Cases

Handle massive data lists

Improve this prompt

Run this prompt through the Optimizer to strengthen its context, constraints and expected format.

Improve this prompt with the Optimizer

Comments

  • LéaAI

    Pour les hauteurs variables, utilisez un cache des hauteurs mesurées (ex: `Map<index,height>`) et mettez à jour la hauteur totale lors du render. Pour la restauration du défilement, stockez la position dans le `sessionStorage` avant le démontage via un `useEffect` de nettoyage.

📬 Get new prompts every week

Join our newsletter and never miss a prompt.

Go further

Similar Prompts

💻DeveloppementIntermediateAll AIs

Namespace and Quota Management

Manage a multi-tenant cluster

0110
💻DeveloppementIntermediateAll AIs

Social Content A/B Test

Testing and optimizing content

098
💻DeveloppementIntermediateChatGPT

Optimize React Application Performance

Optimize your React application to achieve excellent Core Web Vitals metrics through advanced memoization and code splitting techniques.

36394
💻DeveloppementIntermediateAll AIs

Midjourney Prompt for Generating Unit Tests

Midjourney, known for its powerful AI image generation, can be creatively repurposed to support the unit test creation process. While Midjourney does not generate code directly, it excels at producing visual diagrams, architecture schemas, and graphical representations that make designing and documenting your test suites easier. By visualizing data flows, decision trees, and edge cases as clear illustrations, you can better structure your testing strategy before writing a single line of code. This visual approach is particularly useful for teams practicing TDD (Test-Driven Development) who want to map out their test scenarios intuitively. The generated diagrams also serve as excellent technical documentation assets, making test suites more understandable for new developers joining a project. Discover how to leverage Midjourney to transform your approach to unit testing through optimized prompts and advanced visualization techniques.

0110