Tech
The Criteria pattern in NestJS: what a client may ask for is a file, not a signature
The Criteria pattern in NestJS
One single way to filter, sort and paginate any list.
Five parameters and a find()
The example running through this article is a library catalogue. A book stores this:
// src/book/book.schema.ts
@ Schema ({ timestamps : true })
export class Book {
@ Prop () title : string ;
@ Prop ({ type : Types . ObjectId , ref : " Author " }) author : Types . ObjectId ;
@ Prop ()...
Read the full discussion on Dev.to
This article was aggregated from Dev.to. Click to join the conversation.
View on Dev.to