{
"count": 3,
"items": [{ }, { }, { }]
}
const findImages = Image.aggregate(
[
{"$count": "count"},
{"$sort": {[sort]: -1}},
{"$skip": parseInt(skip)},
{"$limit": parseInt(limit)},
{
"$project": {
"userId": 1,
"name": 1,
"tag": 1,
"count": 1
}
}
]);