MDX components.wrapper cant be a client component with output: export #57976
Labels
bug
Issue was opened via the bug report template.
Markdown (MDX)
Related to Markdown with Next.js.
stale
The issue has not seen recent activity.
Link to the code that reproduces this issue
https://github.com/h3rmanj/nextjs-mdx-client-wrapper-repro
To Reproduce
page.mdx
mdx-components.tsx
output
mode toexport
npm run build
Current vs. Expected behavior
Currently the build fails with the following output:
build output
I expected this to work as I haven't done anything special regarding dynamic routes.
Verify canary release
Provide environment information
Which area(s) are affected? (Select all that apply)
App Router, MDX (@next/mdx)
Additional context
If the wrapper component is not a client component, it works.
If output is not set to
export
, it works.Seems like a combination of the two.
The text was updated successfully, but these errors were encountered: