Syntax highlighting is a feature that displays source code, in different colors and fonts according to the category of terms. This feature facilitates writing in a structured language such as a programming language or a markup language as both structures and syntax errors are visually distinct. Highlighting does not affect the meaning of the text itself; it is intended only for human readers.^1
Highlighted Code Blocks
To modify styling and highlight colors edit /assets/css/syntax.css
.
1 | {% highlight css %} |
1 | {% highlight html %} |
1 | {% highlight ruby %} |
Standard Code Block
{% raw %}
{% endraw %}
Fenced Code Blocks
To modify styling and highlight colors edit /assets/css/syntax.css
. Line numbers and a few other things can be modified in _config.yml
. Consult Jekyll’s documentation for more information.
1 | #container { |
1 | {% raw %}<nav class="pagination" role="navigation"> |
1 | module Jekyll |
GitHub Gist Embed
An example of a Gist embed below.