MCPcopy Index your code
hub / github.com/github/docs / getServerSideProps

Function getServerSideProps

pages/[versionId]/graphql/overview/explorer.tsx:45–59  ·  view source on GitHub ↗
(context)

Source from the content-addressed store, hash-verified

43}
44
45export const getServerSideProps: GetServerSideProps<Props> = async (context) => {
46 const req = context.req as any
47 const res = context.res as any
48 const graphqlExplorerUrl =
49 process.env.NODE_ENV === 'production'
50 ? 'https://graphql.github.com/explorer'
51 : 'http://localhost:3000'
52
53 return {
54 props: {
55 mainContext: await getMainContext(req, res),
56 graphqlExplorerUrl,
57 },
58 }
59}

Callers

nothing calls this directly

Calls 1

getMainContextFunction · 0.90

Tested by

no test coverage detected