diff options
Diffstat (limited to 'docs/src/components/RightSidebar/RightSidebar.astro')
-rw-r--r-- | docs/src/components/RightSidebar/RightSidebar.astro | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/src/components/RightSidebar/RightSidebar.astro b/docs/src/components/RightSidebar/RightSidebar.astro index ed1dd37cc..04ce66772 100644 --- a/docs/src/components/RightSidebar/RightSidebar.astro +++ b/docs/src/components/RightSidebar/RightSidebar.astro @@ -2,7 +2,7 @@ import TableOfContents from './TableOfContents.jsx'; import MoreMenu from './MoreMenu.astro'; const {content, githubEditUrl} = Astro.props; -const headers = content.astro.headers; +const headers = content.astro?.headers; --- <style> .sidebar-nav { @@ -19,7 +19,7 @@ const headers = content.astro.headers; </style> <nav class="sidebar-nav" aria-labelledby="grid-right"> <div class="sidebar-nav-inner"> - <TableOfContents client:media="(min-width: 50em)" headers={headers} /> + {headers && <TableOfContents client:media="(min-width: 50em)" headers={headers} />} <MoreMenu editHref={githubEditUrl} /> </div> </nav>
\ No newline at end of file |