When I was using react-markdown, the example code
, something like that didn't render correctly
#1249
-
When I'm using react-markdown, I'm not doing what I want, maybe there's something wrong with the way I'm using it, but everything else is rendering fine except the `` block, please show me the correct way, I guess there's something wrong with string concatenation |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 13 replies
-
@quirkybird please read the support guide for how to ask questions in such a way others can actually help. Asking quality questionsHelp us help you!
|
Beta Was this translation helpful? Give feedback.
-
And to apply those styles after having them in your style.css, do you need to do anything special in the options ? I have this piece of code: import Markdown from 'react-markdown'
import remarkGfm from 'remark-gfm'
export function ExplanationComponent(props: TranslationPopoverProps) {
return (
<div className="max-h-40 max-w-[25em] overflow-y-auto rounded-md p-1 px-2.5 text-left font-fluent text-base text-white">
<Markdown remarkPlugins={[remarkGfm]}>{explanation}</Markdown>
</div>
)
} |
Beta Was this translation helpful? Give feedback.
It works perfectly. You just have CSS (tailwind) that styles code with backticks. Change your CSS