-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nesting nextra within an existing App router application #2688
Comments
Nextra only supports the pages router. #1421 (comment) According the NextJS docs here, you can have the pages and app router at the same time. Although I haven't tested this myself, you could have nextra handle only the
If you do not like this 2 router approach, app router will be supported in Nextra4, you can track it here #2600. As for import Layout from '@/components/customlayout'
export default function MyPage = () => {
return <Layout>/*page contents here*/</Layout>
} |
Hey! Thanks for providing an answer. I did something similar to your answer should someone come to the same problem before the App router is fully supported in Nextra. My folder structure is as your answer suggests and I disabled the default navbar from Nextra. In As you have mentioned, the |
Hi.
I'd like to nest my nextra documention within a page (in terms of the App router). In particular, I want to reuse the same headers and footers from my current Next.js 13 application, not use the navbar from Nextra.
Something like:
where
page.tsx
will render whichever.mdx
page the user is on.As well,
layout.tsx
will wrap thepage.tsx
with the necessary headers and footers.Is this even possible?
The text was updated successfully, but these errors were encountered: