Why is there a significant performance increase when using td and tr to wrap thousands of lines of source code in a listing?
问题 I am currently writing a sophisticated syntax highlighter to properly highlight source code listings. In order to test the performance of my statically generated HTML output (not even while dynamically replacing the DOM) I initially used a 3k LoC file which resultend in an 1 MB HTML and noticed unbearable performance degradation on my first implementation. Previously the output was of this form: <pre> <code> <span class="token import">import</span> <span class="token export-all">*</span> <!--