Commit e013ef8b authored by Deimos's avatar Deimos

Formatting: add info about syntax highlighting

parent fca43c78
Title: Text Formatting Title: Text Formatting
Modified: August 10, 2018 Modified: September 21, 2018
Summary: A reference for markdown used on Tildes Summary: A reference for markdown used on Tildes
[TOC] [TOC]
...@@ -107,7 +107,16 @@ You can also use three backticks: ``` to surround a separate block of code: ...@@ -107,7 +107,16 @@ You can also use three backticks: ``` to surround a separate block of code:
console.log("goodbye"); console.log("goodbye");
``` ```
Or alternatively, indent the entire block of code by 4 spaces. Syntax-highlighting is also supported if you specify the language of the code after the initial triple-backtick. For example, to add highlighting to the above example, it would be:
```javascript
console.log("hello");
console.log("goodbye");
```
Any language supported by the Pygments library will work by specifying the "short name" from the list available here: [http://pygments.org/docs/lexers/](http://pygments.org/docs/lexers/)
You can also create a code block by indenting the entire block of code by 4 spaces instead of using the backtick "fencing", but there is no way to add syntax-highlighting with that method.
### Quotes ### Quotes
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment