finds.dev← search

// the find

nestjsx/crud

★ 4,330 · TypeScript · MIT · updated Jul 2024

NestJs CRUD for RESTful APIs

A decorator-based CRUD generator for NestJS that wires up standard REST endpoints (GET, POST, PATCH, DELETE with filtering, sorting, pagination, and eager relation loading) from a single @Crud() decorator on a controller. It ships a TypeORM service implementation and a companion request builder package for frontend query construction. Aimed at NestJS shops that want boilerplate-free CRUD without writing it themselves.

The query DSL is genuinely useful — filtering on nested relations, multi-column sorting, field selection, and cache control all work through URL params without custom code. The @Override() decorator lets you replace individual generated methods cleanly without ejecting from the whole system. The @nestjsx/crud-request package is a nice touch: the same query builder works on the frontend to construct type-safe query strings. Integration test suite covers real database scenarios with multiple entity shapes, which gives actual confidence in the query generation logic.

The project is effectively unmaintained — last commit July 2024 and issue #784 in the README is a call for help keeping it alive. TypeORM is the only supported ORM; Prisma and Drizzle users are out. The generated endpoints don't support bulk operations cleanly and the createMany endpoint returns a flat array with no transaction guarantee around it. NestJS moves fast and the library's peerDeps lag behind, which means you'll hit version conflict pain on a fresh install against current NestJS.

View on GitHub → Homepage ↗

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →