Files
sign/apps/web/pages/_app.tsx

18 lines
550 B
TypeScript
Raw Normal View History

2022-12-06 14:51:03 +01:00
import "../styles/tailwind.css";
2022-12-06 13:45:23 +01:00
import { ReactElement, ReactNode } from "react";
import type { AppProps } from "next/app";
import { NextPage } from "next";
2022-11-14 23:12:51 +01:00
2022-12-06 13:45:23 +01:00
export type NextPageWithLayout<P = {}, IP = P> = NextPage<P, IP> & {
getLayout?: (page: ReactElement) => ReactNode;
};
type AppPropsWithLayout = AppProps & {
Component: NextPageWithLayout;
};
export default function App({ Component, pageProps }: AppPropsWithLayout) {
const getLayout = Component.getLayout || ((page: any) => page);
return getLayout(<Component {...pageProps} />);
2022-11-14 23:12:51 +01:00
}