template into ui

This commit is contained in:
undefined committed 2020-07-31 13:09:08 +08:00
1 parent 43ee86d34b
commit 8bb389eedd
13 files changed
+70 -206

No files matched your search

+1 -1
View File
@@ -3,7 +3,7 @@ import { ValidationError } from '../error';
export default async function paginate(
cursor: Cursor, page: number, pageSize: number,
): Promise<[any[], number, number]> {
): Promise<[any[]/* docs */, number/* numPages */, number/* count */]> {
if (page <= 0) throw new ValidationError('page');
const [count, pageDocs] = await Promise.all([
cursor.count(),