Draft: Highlight all source code in a webworker instead of highlighting in chunks
What does this MR do and why?
Currently, we highlight source code in chunks dynamically as the user scrolls. While this gives us a lot of performance benefits, highlight.js can lose context of what is being highlighted. Highlighting will be more accurate if all of the source code is highlighted upfront.
This MR highlights all source code in a webworker instead of highlighting in chunks, and then splits the result from highlight.js into chunks that can be rendered as the user scrolls.
Screenshots or screen recordings
TODO
How to set up and validate locally
- Open a large Source File sample.
- The file should be highlighted as expected.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #366531 (closed)