Skip to content

Commit

Permalink
sign up schema #11
Browse files Browse the repository at this point in the history
  • Loading branch information
ElhamFadel committed Oct 25, 2021
1 parent 0b3fdac commit 0bbcb36
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions server/utils/validation/signUpSchema.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
const joi = require('joi');

module.exports = joi.object({
name:joi.string().required(),
email: joi.string().email().required(),
password: joi.string().min(5).required(),
//like +911234567890
phone: joi.string().pattern(/^\+[0-9]{2}[0-9]{9}$/).required(),
})

0 comments on commit 0bbcb36

Please sign in to comment.