uiwjs / react-textarea-code-editor

A simple code editor with syntax highlighting.
https://uiwjs.github.io/react-textarea-code-editor/
MIT License
480 stars 22 forks source link

Bug: Markdown: JS/JSX Codeblock return is not displayed. #101

Closed ShubhamVerma1811 closed 2 years ago

ShubhamVerma1811 commented 2 years ago

Steps to reproduce:

  1. Go to the link and select markdown https://uiwjs.github.io/react-textarea-code-editor/
  2. Paste in the below code
const Comp = () => {
return <IAmHidden/>
}
const Comp = () => {
return <IAmAlsoHidden></IAmAlsoHidden>
}

Expectation: Syntax highlight should detect return type component

image

ShubhamVerma1811 commented 2 years ago

Looks like it's not just js jsx

Anything between <> causes the issue inside the codeblocks

jaywcjlove commented 2 years ago

@ShubhamVerma1811 Upgrade v1.5.2

ShubhamVerma1811 commented 2 years ago

Can confirm it's fixed!

Thank you @jaywcjlove!