perf: Use one PageWrapper instance for every non-settings / non-bookings page in App Router (#18747)

* add a layoutfile to use-page-wrapper route group

* refactor and move bookings status page to route group

* improve logic in pagesAndRewritePaths

* fix

* add use client directive

* move /403 and /500

* move /auth/error

* move /connect-and-join

* move /enterprise

* move /maintenance

* move /more

* move /upgrade

* chore: remove WithLayout from 8 low-risk single pages (#18745)

* move /403 and /500

* move /auth/error

* move /connect-and-join

* move /enterprise

* move /maintenance

* move /more

* move /upgrade

* move /availability pages

* move /event-types pages

* move /insights pages

* move /apps to use-page-wrapper group

* move /getting-started to use-page-wrapper group

* move /signup to use-page-wrapper group

* move /workflows to use-page-wrapper group

* move /video pages to use-page-wrapper group

* pass dehydratedState in layout

* pass dehydratedState in layout

* fix test

* fix @test

* fix
This commit is contained in:
Benny Joo authored and GitHub committed 2025-01-23 10:01:46 -05:00
1 parent 2335aba843
commit 8e191fed71
26 files changed
+164 -127

No files matched your search

@@ -1,19 +0,0 @@
import type { ComponentProps } from "react";
import React, { Suspense } from "react";
import type Shell from "@calcom/features/shell/Shell";
import { ErrorBoundary, Icon } from "@calcom/ui";
export default function TroubleshooterLayout({
children,
}: { children: React.ReactNode } & ComponentProps<typeof Shell>) {
return (
<div className="flex flex-1 [&>*]:flex-1">
<ErrorBoundary>
<Suspense fallback={<Icon name="loader" />}>{children}</Suspense>
</ErrorBoundary>
</div>
);
}
export const getLayout = (page: React.ReactElement) => <TroubleshooterLayout>{page}</TroubleshooterLayout>;