mirror of
https://github.com/randyjc/Rahoot.git
synced 2026-03-13 20:15:35 +01:00
feat: improve reconnect, add ESLint configuration for common and socket
This commit is contained in:
8
packages/common/src/validators/auth.ts
Normal file
8
packages/common/src/validators/auth.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import z from "zod"
|
||||
|
||||
export const usernameValidator = z
|
||||
.string()
|
||||
.min(4, "Username cannot be less than 4 characters")
|
||||
.max(20, "Username cannot exceed 20 characters")
|
||||
|
||||
export const inviteCodeValidator = z.string().length(6, "Invalid invite code")
|
||||
Reference in New Issue
Block a user