Implement Auth provide user info

This commit is contained in:
Takeshi Kimata
2024-05-19 11:14:04 +09:00
parent 0a783bddfd
commit 3d141cf05b
16 changed files with 151 additions and 7 deletions

View File

@@ -0,0 +1,19 @@
function isValidEmail(email: string) {
const validRegex =
/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$/;
if (email.match(validRegex)) {
return true;
} else {
return false;
}
}
function isValidPassword(password: string) {
if (password.length > 7) {
return true;
} else {
return false;
}
}
export { isValidEmail, isValidPassword };