erikolson186 / zangodb

MongoDB-like interface for HTML5 IndexedDB
https://erikolson186.github.io/zangodb/
MIT License
1.07k stars 72 forks source link

Add count support #35

Open wideweide opened 5 years ago

wideweide commented 5 years ago

How to get count directly?

people.find({ name: { $regex: /Todd/ } }).toArray().then(res => console.log(res.length)).catch(err =>console.log(err))

may be add count support? people.count({ name: { $regex: /Todd/ } }).then(res => console.log(res)).catch(err =>console.log(err))