Code
Installation quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut laboe et doloreagnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi aliquid ex ea commodi consequatur? Quis autem vel eum iure
Rrem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut laboe et dolore gnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum
Inline code
Wrap inline snippets of code with <code>
. Be sure to escape HTML angle brackets.
For example, <section>
should be wrapped as inline.
Code blocks
Use <pre>
s for multiple lines of code. Once again, be sure to escape any angle brackets in the code for proper rendering. You may optionally add the .pre-scrollable
class, which will set a max-height of 340px and provide a y-axis scrollbar.
<p>Sample text here...</p>
<p>And another line of sample text here...</p>
Variables
For indicating variables use the <var>
tag.
User input
Use the <kbd>
to indicate input that is typically entered via keyboard.
To switch directories, type cd followed by the name of the directory.
To edit settings, press ctrl + ,
Sample output
For indicating sample output from a program use the <samp>
tag.
This text is meant to be treated as sample output from a computer program.
Syntax highlighter
Styles for inline code snippets and longer, multiline blocks of code.
Overview
We use PrismJs to syntax highlight code snippets. You have to put your code inside <pre><code class="language-xxxx">
which xxxx
is the name of language.
If you need to include line numbers, add class .line-numbers
to the <pre>
tag.
Supported languages
This is the list of all languages currently supported by Prism, with their corresponding alias, to use in place of xxxx
in the language-xxxx
class:
- HTML/XML
markup
- CSS
css
- C-like
clike
- JavaScript
javascript
- ASP.NET (C#)
aspnet
- Bash
bash
- C
c
- C#
csharp
- C++
cpp
- CoffeeScript
coffeescript
- Git
git
- HTTP
http
- Ini
ini
- Java
java
- LaTeX
latex
- Less
less
- MATLAB
matlab
- Objective-C
objectivec
- Perl
perl
- PHP
php
- Python
python
- Ruby
ruby
- Sass (Scss)
scss
- SQL
sql
- Swift
swift