Getting Started
Nestjs-Query is collection of packages to make crud for graphql
(and potentially other transports) easier.
Why?
While working on projects in nestjs it was very easy to get up and running with typeorm and graphql however, there were many patterns that were common between the resolvers. In particular querying, sorting and paging.
Features
- Built on top of nestjs
- Out of the box CRUD for GraphQL using TypeORM, Sequelize or Mongoose
- Aggregate Queries on objects and their relations.
- Out of the box subscriptions on all
CRUD
operations. - Support for one to one, one to many, many to one and many to many relations.
- Built in dataloader avoiding the
n+1
problem - Relay connections for paging results
Install
Check out the installation docs
Packages
Nestjs-query is composed of multiple packages
@ptc-org/nestjs-query-core
- Defines all interfaces and utility types implemented by the other packages.@ptc-org/nestjs-query-graphql
- Package that provides the graphql resolver and decorators for crud endpoints.@ptc-org/nestjs-query-typeorm
- Package that implements a Typeorm service that can be used by itself or with the graphql resolver provided by@ptc-org/nestjs-query-graphql
.@ptc-org/nestjs-query-sequelize
- Package that implements a Sequelize service that can be used by itself or with the graphql resolver provided by@ptc-org/nestjs-query-graphql
.@ptc-org/nestjs-query-mongoose
- Package that implements a Mongoose service that can be used by itself or with the graphql resolver provided by@ptc-org/nestjs-query-graphql
.@ptc-org/nestjs-query-typegoose
- Package that implements a Typegoose service that can be used by itself or with the graphql resolver provided by@ptc-org/nestjs-query-graphql
.