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