Steps to Register an User:
- Get all the Imformation (JSON Format). [Use the Middleware]
- What is a middleware?
- Something which happens in middle...
- Example:
- Check all the Mandatory Fields. [Mongoose Model Validation]
- Already Register (Take care of this situation) [Mongoose Query]
- Take care of Password (Crypt it).
- Generate Token or Send the Success Message.