react-diff-viewer icon indicating copy to clipboard operation
react-diff-viewer copied to clipboard

Prism syntax highlighting does not work for multi-line comments

Open ebramanti opened this issue 2 years ago • 0 comments

Syntax highlighting is only applied on a per-line basis due to how the renderContent API is designed. Because it only syntax highlights one line at a time, multi-line comments are not rendered properly.

Here is an update to the example of the multi-line comment: https://github.com/praneshr/react-diff-viewer/compare/master...ebramanti:react-diff-viewer:syntax-highlighting-bug

And what it looks like rendered: image

ebramanti avatar Apr 07 '23 17:04 ebramanti