forked from
npmx.dev/npmx.dev
[READ-ONLY]
a fast, modern browser for the npm registry
1import { object, string, pipe, url, optional } from 'valibot'
2import type { InferOutput } from 'valibot'
3
4export const PublicUserSessionSchema = object({
5 // Safe to pass to the frontend
6 did: string(),
7 handle: string(),
8 pds: pipe(string(), url()),
9 avatar: optional(pipe(string(), url())),
10})
11
12export type PublicUserSession = InferOutput<typeof PublicUserSessionSchema>