Merge pull request #28 from fqd511/feature/improve-slug-readability

feat: improve slug readability
This commit is contained in:
面条 2024-07-30 20:12:47 +08:00 committed by GitHub
commit ef3e704d79
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -5,7 +5,7 @@ const { slugRegex } = useAppConfig()
const slugDefaultLength = +useRuntimeConfig().public.slugDefaultLength
export const nanoid = (length: number = slugDefaultLength) => customAlphabet('23456789abcdefghjklmnpqrstuvwxyz', length)
export const nanoid = (length: number = slugDefaultLength) => customAlphabet('23456789abcdefghjkmnpqrstuvwxyz', length)
export const LinkSchema = z.object({
id: z.string().trim().max(26).default(nanoid(10)),