FormSchema() — supabase Function Reference
Architecture documentation for the FormSchema() function in CreateHookSheet.tsx from the supabase codebase.
Entity Profile
Relationship Graph
Source Code
apps/studio/components/interfaces/Auth/Hooks/CreateHookSheet.tsx lines 72–106
.superRefine((data, ctx) => {
if (data.selectedType === 'https') {
if (!data.httpsValues.url.startsWith('https://')) {
ctx.addIssue({
path: ['httpsValues', 'url'],
code: z.ZodIssueCode.custom,
message: 'The URL must start with https://',
})
}
if (!data.httpsValues.secret) {
ctx.addIssue({
path: ['httpsValues', 'secret'],
code: z.ZodIssueCode.custom,
message: 'Missing secret value',
})
}
}
if (data.selectedType === 'postgres') {
if (!data.postgresValues.schema) {
ctx.addIssue({
path: ['postgresValues', 'schema'],
code: z.ZodIssueCode.custom,
message: 'You must select a schema',
})
}
if (!data.postgresValues.functionName) {
ctx.addIssue({
path: ['postgresValues', 'functionName'],
code: z.ZodIssueCode.custom,
message: 'You must select a Postgres function',
})
}
}
return true
})
Domain
Subdomains
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free