CodeBlock render code without theme #867
Answered
by
fuma-nama
Ali-Hussein-dev
asked this question in
Q&A
-
Beta Was this translation helpful? Give feedback.
Answered by
fuma-nama
Sep 16, 2024
Replies: 1 comment 2 replies
-
Hmm guess you misunderstood what the component does. It styles the output of Rehype Code (our tiny wrapper over Shiki), and you are supposed to use it with Markdown/MDX. Your usage requires syntax highlighting with Shiki and render the Hast tree with code block component. I would suggest you to take a look at our source code of landing page, or see Shiki's Next.js integration guide (as I wrote it, I can confirm it's correct) |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
Ali-Hussein-dev
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hmm guess you misunderstood what the component does. It styles the output of Rehype Code (our tiny wrapper over Shiki), and you are supposed to use it with Markdown/MDX.
Your usage requires syntax highlighting with Shiki and render the Hast tree with code block component.
I would suggest you to take a look at our source code of landing page, or see Shiki's Next.js integration guide (as I wrote it, I can confirm it's correct)