Answers for "mangoose filter collection based on string match"

0

mangoose filter collection based on string match

const s = 'cool'
const regex = new RegExp(s, 'i') // i for case insensitive
Posts.find({title: {$regex: regex}})
Posted by: Guest on May-02-2021

Code answers related to "mangoose filter collection based on string match"

Browse Popular Code Answers by Language