Check out example codes for "how to perform or operation in mongo db". It will help you in understanding the concepts better.

Code Example 1

db.contributor.find({$or: [{branch: "ECE"}, 
                     {joiningYear: 2017}]}).pretty()

Learn ReactJs, React Native from akashmittal.com