♻️ Export bot-engine code into its own package
This commit is contained in:
4
packages/bot-engine/blocks/inputs/email/validateEmail.ts
Normal file
4
packages/bot-engine/blocks/inputs/email/validateEmail.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
const emailRegex =
|
||||
/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/
|
||||
|
||||
export const validateEmail = (email: string) => emailRegex.test(email)
|
||||
Reference in New Issue
Block a user