Files
supabase/apps/docs/layouts/DefaultGuideLayout.tsx
Charis 7cf2eae953 fix: statically build the right nav on each page (#21469)
Before: All pages have the Home nav menu in static HTML, which is blown away and replaced by the proper nav menu upon hydration. This leads to jankiness when the page first loads and an unpleasant flash of the wrong nav menu (especially obvious on the JavaScript ref page, which takes a long time to process and rerender the nav).

Now: All pages have their correct nav menu in static HTML.
2024-02-23 11:38:06 -05:00

28 lines
682 B
TypeScript

import { FC } from 'react'
import { FooterHelpCalloutType } from '~/components/FooterHelpCallout'
import { type MenuId } from '~/components/Navigation/NavigationMenu/NavigationMenu'
import GuideLayout from './guides'
interface Props {
meta: {
title: string
description?: string
hide_table_of_contents?: boolean
video?: string
footerHelpType?: FooterHelpCalloutType
}
children: any
toc?: any
// [Charis] Deprecate meta.hide_table_of_contents once the content migration is over
hideToc?: boolean
currentPage?: string
editLink?: string
menuId: MenuId
}
const Layout: FC<Props> = (props) => {
return GuideLayout(props)
}
export default Layout