Flutter Performance
ASecurityThe lag is likely because `Column` builds all 500 `ProductCard`s at once, so Flutter has to layout, paint, and keep every child alive during scroll. Use `ListView.builder` instead so items are built lazily and recycled: ```dart ListView.builder( itemCount: products.length, itemBuilder: (context, index) { final product = products[index]; return ProductCard( key: ValueKey(product.id), product: product, ); }, ) ``` Also make sure: - `ProductCard` uses `const` where possible - each row has a stab...
- 584 stars
- 0 votes
- 0 copies
- 4 views
- Added September 5, 2026
Security analysis
100/100Pro scans all 12 files and shows the line behind each finding
npx -y skills add HoangNguyen0403/agent-skills-standard --skill flutter-performance --agent claude-codeAre you the author of Flutter Performance?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/hoangnguyen0403-flutter-performance-agent-skills-standard)The lag is likely because `Column` builds all 500 `ProductCard`s at once, so Flutter has to layout, paint, and keep every child alive during scroll.
Use `ListView.builder` instead so items are built lazily and recycled:
```dart
ListView.builder(
itemCount: products.length,
itemBuilder: (context, index) {
final product = products[index];
return ProductCard(
key: ValueKey(product.id),
product: product,
);
},
)
```
Also make sure:
- `ProductCard` uses `const` where possible
- each row has a stable `ValueKey`
- heavy sorting/filtering/image prep is not done inside `build()`
- controllers/streams are disposed properly
If `ProductCard` is visually complex, consider wrapping it in `RepaintBoundary`. If images are involved, resize/cache them appropriately.
Files in this skill
- eval-1.baseline.md
- eval-1.with-skill.md
- eval-2.baseline.md
- eval-2.with-skill.md
- eval-3.baseline.md
- eval-3.with-skill.md
- trigger-1.md
- trigger-2.md
- trigger-3.md
- trigger-4.md
- trigger-5.md
Attribution
Related skills
View all in development →Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.