feat: improve slug readability
(cherry picked from commit d950387f8cc87b166fd24bd75276bf34e1c5daa5)
This commit is contained in:
parent
2856c4013f
commit
08ed8da522
@ -5,7 +5,7 @@ const { slugRegex } = useAppConfig()
|
||||
|
||||
const slugDefaultLength = +useRuntimeConfig().public.slugDefaultLength
|
||||
|
||||
export const nanoid = (length: number = slugDefaultLength) => customAlphabet('0123456789abcdefghijklmnopqrstuvwxyz', length)
|
||||
export const nanoid = (length: number = slugDefaultLength) => customAlphabet('23456789abcdefghjkmnpqrstuvwxyz', length)
|
||||
|
||||
export const LinkSchema = z.object({
|
||||
id: z.string().trim().max(26).default(nanoid(10)),
|
||||
|
||||
Loading…
Reference in New Issue
Block a user