diff --git a/client/src/app.tsx b/client/src/app.tsx index acb48758f1d7..1d18c0cfc82b 100644 --- a/client/src/app.tsx +++ b/client/src/app.tsx @@ -18,6 +18,7 @@ import { useGleanPage } from "./telemetry/glean-context"; import { MainContentContainer } from "./ui/atoms/page-content"; import { Loading } from "./ui/atoms/loading"; import { HydrationData } from "../../libs/types/hydration"; +import PageNotFound from "./page-not-found"; import { TopPlacement } from "./ui/organisms/placement"; const About = React.lazy(() => import("./about")); @@ -29,7 +30,6 @@ const ContributorSpotlight = React.lazy( ); const Homepage = React.lazy(() => import("./homepage")); const Newsletter = React.lazy(() => import("./newsletter")); -const PageNotFound = React.lazy(() => import("./page-not-found")); const Playground = React.lazy(() => import("./playground")); const SiteSearch = React.lazy(() => import("./site-search")); diff --git a/client/src/document/index.tsx b/client/src/document/index.tsx index deab65397a73..ed19fb8087d2 100644 --- a/client/src/document/index.tsx +++ b/client/src/document/index.tsx @@ -44,12 +44,12 @@ import { useIncrementFrequentlyViewed } from "../plus/collections/frequently-vie import { useInteractiveExamplesActionHandler as useInteractiveExamplesTelemetry } from "../telemetry/interactive-examples"; import { BottomBanner, SidePlacement } from "../ui/organisms/placement"; import { BaselineIndicator } from "./baseline-indicator"; +import PageNotFound from "../page-not-found"; import { PlayQueue } from "../playground/queue"; // import { useUIStatus } from "../ui-context"; // Lazy sub-components const MathMLPolyfillMaybe = React.lazy(() => import("./mathml-polyfill")); -const PageNotFound = React.lazy(() => import("../page-not-found")); const Toolbar = React.lazy(() => import("./toolbar")); export class HTTPError extends Error { diff --git a/client/src/homepage/static-page/index.tsx b/client/src/homepage/static-page/index.tsx index be52cd6f3031..09e56bcf5148 100644 --- a/client/src/homepage/static-page/index.tsx +++ b/client/src/homepage/static-page/index.tsx @@ -5,8 +5,7 @@ import { SidebarContainer } from "../../document/organisms/sidebar"; import { TOC } from "../../document/organisms/toc"; import { Toc } from "../../../../libs/types/document"; import { Loading } from "../../ui/atoms/loading"; - -const PageNotFound = React.lazy(() => import("../../page-not-found")); +import PageNotFound from "../../page-not-found"; interface StaticPageDoc { id: string; diff --git a/client/src/plus/index.tsx b/client/src/plus/index.tsx index 9afbcae0ac49..3ba40d55a7f6 100644 --- a/client/src/plus/index.tsx +++ b/client/src/plus/index.tsx @@ -7,13 +7,13 @@ import { MainContentContainer } from "../ui/atoms/page-content"; import { MDN_PLUS_TITLE } from "../constants"; import { ArticleActionsContainer } from "../ui/organisms/article-actions-container"; import { DocParent } from "../../../libs/types/document"; +import PageNotFound from "../page-not-found"; import "./index.scss"; const AiHelp = React.lazy(() => import("./ai-help")); const Collections = React.lazy(() => import("./collections")); const OfferOverview = React.lazy(() => import("./offer-overview")); -const PageNotFound = React.lazy(() => import("../page-not-found")); const PlusDocs = React.lazy(() => import("./plus-docs")); const Settings = React.lazy(() => import("../settings")); const Updates = React.lazy(() => import("./updates"));