Files
imphnen-frontend-service/libs/service/src/schemas/auth/index.ts
T

18 lines
472 B
TypeScript
Raw Normal View History

2025-04-03 12:21:10 +07:00
import { z } from 'zod';
export const authLoginSchema = z.object({
email: z
2025-04-03 19:40:04 +07:00
.string({
required_error: 'Email tidak boleh kosong',
invalid_type_error: 'Email harus berupa string',
})
.min(1, 'Email tidak boleh kosong')
.email('Email harus valid'),
password: z
.string({
required_error: 'Password tidak boleh kosong',
invalid_type_error: 'Password harus berupa string',
})
.min(1, 'Password tidak boleh kosong'),
2025-04-03 12:21:10 +07:00
});