n-plus-one-prevention
CommunityPrevent N+1 queries with a single fetch.
Authoryanko-belov
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill helps developers avoid N+1 database queries by promoting eager loading and efficient data access patterns.
Core Features & Use Cases
- Eager loading guidance: Learn how to fetch related data in a single query across popular ORMs (e.g., Sequelize, Prisma, TypeORM).
- Loop optimization: Detect and replace per-item queries inside loops with bulk or joined queries.
- Real-world scenario: Turn a two-step process that queries orders and then their customers into a single optimized query path.
Quick Start
Refactor a loop that queries related data for each item into a single, joined or bulk-loaded query.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: n-plus-one-prevention Download link: https://github.com/yanko-belov/code-craft/archive/main.zip#n-plus-one-prevention Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.