4 ms·
> Let's start with something simple, like syntax highlighting. I built a syntax highlighter, Shiki, that allows you to use any theme from VS Code to color your
by octref 7y ago
> Let's start with something simple, like syntax highlighting.
I built a syntax highlighter, Shiki, that allows you to use any theme from VS Code to color your code [0]. It works great with Node now as a static website generator plugin, but with some effort you can run it all in client side as well. TypeScript's new handbook is using Shiki [1].
I can't really believe how it's 2019 and Medium and Slack still can't syntax highlight code snippets.
[0]: http://shiki.matsu.io/ http://shiki.matsu.io/
[1]: https://microsoft.github.io/TypeScript-New-Handbook/chapters/classes/ https://microsoft.github.io/TypeScript-New-Handbook/chapters...
- caspervonb 7y agoSyntax highlighting add any information tho, without it it's easier to bring focus to elements that matter with emphasis.