2022-07-14 09:40:53 -03:00
|
|
|
import { GetServerSidePropsContext, GetServerSidePropsResult } from "next";
|
|
|
|
import { CalendsoSessionUser } from "next-auth";
|
|
|
|
|
2022-08-22 16:34:28 -03:00
|
|
|
import prisma from "@calcom/prisma";
|
2022-07-14 09:40:53 -03:00
|
|
|
|
2022-11-03 11:40:03 -03:00
|
|
|
import type { ssrInit } from "@server/lib/ssr";
|
|
|
|
|
2022-07-14 09:40:53 -03:00
|
|
|
export type AppUser = CalendsoSessionUser | undefined;
|
|
|
|
export type AppPrisma = typeof prisma;
|
|
|
|
export type AppGetServerSidePropsContext = GetServerSidePropsContext<{
|
|
|
|
appPages: string[];
|
|
|
|
}>;
|
2022-11-03 11:40:03 -03:00
|
|
|
export type AppSsrInit = ssrInit;
|
2022-07-14 09:40:53 -03:00
|
|
|
export type AppGetServerSideProps = (
|
|
|
|
context: AppGetServerSidePropsContext,
|
|
|
|
prisma: AppPrisma,
|
2022-11-03 11:40:03 -03:00
|
|
|
user: AppUser,
|
|
|
|
ssrInit: AppSsrInit
|
2022-07-14 09:40:53 -03:00
|
|
|
) => GetServerSidePropsResult;
|