EdgeFunction() — supabase Function Reference
Architecture documentation for the EdgeFunction() function in EdgeFunction.tsx from the supabase codebase.
Entity Profile
Relationship Graph
Source Code
apps/studio/components/interfaces/ProjectAPIDocs/Content/EdgeFunction.tsx lines 9–39
export const EdgeFunction = ({ language, apikey = 'API_KEY', endpoint }: ContentProps) => {
const { ref } = useParams()
const snap = useAppStateSnapshot()
const { data } = useEdgeFunctionsQuery({ projectRef: ref })
const resource = snap.activeDocsSection[1]
const edgeFunctions = data ?? []
const edgeFunction = edgeFunctions.find((fn) => fn.name === resource)
if (edgeFunction === undefined) return null
return (
<div className="divide-y">
<div className="space-y-1 px-4 py-4">
<div className="flex items-center space-x-2">
<h2>{edgeFunction.name}</h2>
</div>
</div>
<ResourceContent
selectedLanguage={language}
snippet={DOCS_RESOURCE_CONTENT.invokeEdgeFunction}
codeSnippets={DOCS_RESOURCE_CONTENT.invokeEdgeFunction.code({
name: resource,
endpoint: `${endpoint}`,
apikey: apikey,
})}
/>
</div>
)
}
Domain
Subdomains
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free