2020-11-27 19:27:44 +01:00
|
|
|
export function validateEmailField(value: string): boolean | string {
|
2020-02-18 08:57:00 +01:00
|
|
|
return value.includes("@") || "Invalid e-mail.";
|
2019-01-11 13:58:29 +01:00
|
|
|
}
|
|
|
|
|
2020-11-27 19:27:44 +01:00
|
|
|
export function validateRequiredField(value: unknown): boolean | string {
|
2020-02-18 08:57:00 +01:00
|
|
|
return !!value || "Required.";
|
2019-01-11 13:58:29 +01:00
|
|
|
}
|