Check out example codes for "mongo delete all documents". It will help you in understanding the concepts better.

Code Example 1

db.bios.remove( { } )

Code Example 2

db.collection.remove(
   <query>,
   {
     justOne: <boolean>,
     writeConcern: <document>
   }
)

Code Example 3

db.collection.delete_many( { } );

Learn ReactJs, React Native from akashmittal.com