Skip to content
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

Error: Language cs not supported #55

Open
cuongdo926 opened this issue Oct 22, 2021 · 6 comments
Open

Error: Language cs not supported #55

cuongdo926 opened this issue Oct 22, 2021 · 6 comments

Comments

@cuongdo926
Copy link

I used the below code. I tried both language csharp and cs. There is an error in the dev version but the style is still applied for the code block.
In the build production version, the error is still there but there is no style for code. How can I fix this?

<CopyBlock
   language='csharp'
   text={codeString}
   wrapLines
   showLineNumbers
   theme={sunburst}
   codeBlock
 ></CopyBlock>

image

@laurawarr
Copy link

I'm having the same issue, and I believe it's a bug. From what I can see csharp is mapped to cs and passed to the PrismAsyncLight component from react-syntax-highlighter which expects csharp as the language.

@laurawarr
Copy link

@rajinwonderland can you confirm? I'd be happy to submit a PR

@anonomity
Copy link

I have the same issue, cs and csharp don't work

@DCosti
Copy link

DCosti commented Feb 24, 2022

Hi. I am using v0.0.9-0 of react-code-blocks with react v16.14.0 and I am still getting this error? Do you have any updates on this? Thanks!

@mdubus
Copy link

mdubus commented Mar 24, 2022

Hello!
Same here, any news on this? Thanks 🙏

@laurawarr
Copy link

I ended up just switching to use react-syntax-highlighter instead

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants