Make a CookieOptions object for use with getCookie, setCookie, and deleteCookie. The schema should be compatible with JSON meaning only null, booleans, numbers, strings, arrays, and objects can be used.
null
const MyCookie = makeCookieOptions({ name: "<unique name>", schema: z.object({ foo: z.string() }) }) Copy
const MyCookie = makeCookieOptions({ name: "<unique name>", schema: z.object({ foo: z.string() }) })
Make a CookieOptions object for use with getCookie, setCookie, and deleteCookie. The schema should be compatible with JSON meaning only
null, booleans, numbers, strings, arrays, and objects can be used.Example