Tab size of code blocks
Igor Zhbanov
izh1979 at gmail.com
Sun Oct 2 06:24:54 EDT 2016
Hi.
Markdown allows to include code blocks by using
```c
printf("Hello World\n");
```
But it doesn't allow to specify the tab size (number of spaces). As I see,
Markdown states that the tab size is 4: "To produce a code block
in Markdown, simply indent every line of the block by at least 4 spaces
or 1 tab."
We use Markdown as a format for projects' wikis in gitlab. And we need
sometimes to include snippets of code to wiki pages. And lot of projects
use tab size of 8. It would be nice to allow to specify the tab size per
code block. For example (or with any other syntax):
```c;tab-size=8
printf("Hello World\n");
```
(Or there could be some global setting at the start of the file.)
This would allow markdown to HTML converters to set the tab-size CSS
property properly. What you think?
Thank you.
More information about the Markdown-Discuss
mailing list