To pull all the documents out sorted by the date they joined in ascending order, we would do the following:
db.users.find().sort({dateJoined: 1})
Notice that sort takes an argument of an object describing how to sort the data. Each field in the object can have a value of 1 (ascending) or -1 (descending)