The highlighter currently isn't very efficient at syntax highlighting. It takes ~4 seconds to highlight ~1900 loc. Also, spaces, newlines and tabs are counted as tokens, but can be merged into other tags as they don't have a foreground color. Tokens of the same color are also separated into different <span> tags, whilst it would be more efficient and space-saving to have them in the same tag element.
e.g., the 1900 loc. example output file takes 1.4 MB when an equivalent version (made using this) is only ~500KB.
The highlighter currently isn't very efficient at syntax highlighting. It takes ~4 seconds to highlight ~1900 loc. Also, spaces, newlines and tabs are counted as tokens, but can be merged into other tags as they don't have a foreground color. Tokens of the same color are also separated into different
<span>tags, whilst it would be more efficient and space-saving to have them in the same tag element.e.g., the 1900 loc. example output file takes 1.4 MB when an equivalent version (made using this) is only ~500KB.