[RSC - client directive] : Not working has expected #423
Unanswered
StephaneIzi
asked this question in
Q&A
Replies: 1 comment
-
|
Possibly related to this #309 (comment) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, first thank you for this amazing repository ❤️ .
contentlayerhas been really useful to me lately.TLDR : Should i expect
contentlayerto handle React Component withclient directiveinside MDX ?I want to use
contentlayerto hold all my content (mdxfiles)The stack is :
nextJS 13contentlayertailwindHere is a repo with the stack : https://github.com/Stephane-Pires/contentlayer-mdx-client-directive
I started with MDX using @next/mdx (commit : 1ef8551c6206eb44f0f1717f2f8c32eef7da22d0) , everything was working fine, i was able to import Component with and without
use clientdirective directly inside mymdxfiles. (Below agifof the working<Counter />Button)file : https://github.com/Stephane-Pires/contentlayer-mdx-client-directive/blob/main/content/hello.mdx
Screen.Recording.2023-04-16.at.18.58.20.mov
Then i tryied MDX using @contentlayer & @next-contentlayer(commit : a3c027e455de3fda8b329ad2e2113b0c38c042e4)
I configured
contentlayerRemoved the
<Counter />component from the MDXgenerate the
.contentlayerwith the CLInpx contentlayer builddue to No.contentlayerfolder is generated in Next.js 13.3 #415 (i think)Everything is working has expected.
Things started to go off track when i added the
<Counter />component insideMDXfiles.I tryied :
From my understanding so far,
contentlayercould handle Client Componenthttps://github.com/contentlayerdev/contentlayer/releases
My question is : Should i expect
contentlayerto handle React Component withclient directiveinside MDX ?P.S : I really want to use
contentlayerthetypesgeneration is a big plus for me !Thanks for reading !
Beta Was this translation helpful? Give feedback.
All reactions