* [CAL-1517] fix all Typescript warnings * solve conflicts * Update stripeCheckoutSession.handler.ts Parse is a guard, so even though the variable is unused the parse itself is needed. * Update ToolbarPlugin.tsx Don't change dependency tree --------- Co-authored-by: gitstart-calcom <gitstart@users.noreply.github.com> Co-authored-by: Peer Richelsen <peeroke@gmail.com> Co-authored-by: Alex van Andel <me@alexvanandel.com>
11 lines
396 B
TypeScript
11 lines
396 B
TypeScript
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
type GetSSRResult<TProps> =
|
|
//
|
|
{ props: TProps } | { redirect: { destination: string; permanent: boolean } } | { notFound: boolean };
|
|
|
|
type GetSSRFn<TProps> = (...args: any[]) => Promise<GetSSRResult<TProps>>;
|
|
|
|
export type inferSSRProps<TFn extends GetSSRFn<any>> = TFn extends GetSSRFn<infer TProps>
|
|
? NonNullable<TProps>
|
|
: never;
|