This post refers to a legacy version of Siteleaf.
In the last Siteleaf post, we explored taxonomy and the many ways you could use it to extend your website. This time, we’ll break from templating and take a closer look at content—specifically, Markdown’s role in Siteleaf.
If you develop for the web and haven’t heard of Markdown yet, I’m going to have to ask you to leave. As described by its originator, John Gruber, “Markdown is a text-to-HTML conversion tool for web writers.” With it, we can write a blog post, like this one, and style it without touching HTML. Instead of typing
<strong>bold</strong> for a selection of text we’d like to bold, we can type
**bold** and use a Markdown engine to produce the proper HTML syntax. This allows for more legible text when writing, so we don’t lose track of the actual words.
Along with styling, we can also use Markdown for more complex elements, like links:
[alt text](http://mylink.com), and images:
![alt text](/myimage.jpg). Under the hood, Siteleaf uses Redcarpet, a widely-adopted Markdown engine, and SmartyPants, a plugin for automatic smart quotes and other fancy characters. With these libraries, we get a few extra shortcuts for free, like em dashes:
..., and tables:
| First name | Last name | Age |
| ---------- | ----------- | --- |
| Jonnie | Hallman | 26 |
| Larry | Fox | 15 |
| Sawyer | Hollenshead | 14 |
With the support of Markdown, Siteleaf posts can follow our guiding principle—all content should outlive its CMS. No matter where you manage your website, you should be able to take your content with you, free from any ties to the previous system.