typeorm pagination how to code example
Example: typeorm pagination
@EntityRepository(Issue)
export class IssueRepository extends Repository {
findAll(take = 20, page = 1) {
return this.find({ take, skip: take * (page - 1) });
}
}
@EntityRepository(Issue)
export class IssueRepository extends Repository {
findAll(take = 20, page = 1) {
return this.find({ take, skip: take * (page - 1) });
}
}