这个sample的md文件在这里。
这是h1
这是h2
这是h3
这是h4
这是h5
这是h6
这是区块引用。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。这是很多文字。
这是区块引用的第二段
区块引用可以嵌套
根据层次使用不同数量的>即可
就像上面那样
还可以在区块引用中使用其他md语法
像这个h3
- 这是无序列表的列表项1
- 这是无序列表的列表项2
- 这是无序列表的列表项3
- 这是有序列表的列表项1
- 这是有序列表的列表项2
- 这是有序列表的列表项3
点击这里可以打开google
这是一个参考式的链接,点击可返回首页。链接内容可以在文档任何位置定义出来。
一个 * 是em标签的强调,两个 * 是strong标签的强调
看一下在普通文字中的强调em样式的样子,以及strong中的强调em样式。
行内代码使用反引号包围起来,像这样:<p>Hello world!</p>
若代码中存在反引号,则可以用多个反引号来开启结束代码片段,像这样:SELECT * FROM `table`
这是区块代码:
#include<stdio.h>
int main()
{
printf("Hello World");
return 0;
}
<html>
<head>
<title><?= 'Fibonacci numbers' ?></title>
<?php
// PHP has a plethora of comment types
/* What is a
"plethora"? */
function fib($n) {
# I don't know.
$a = 1;
$b = 1;
while (--$n >= 0) {
echo "$a\n";
$tmp = $a;
$a += $b;
$b = $tmp;
}
}
?>
</head>
<body>
<?= fib(10) ?>
</body>
</html>
def fib():
'''
a generator that produces the fibonacci series's elements
'''
a = 1
b = 1
while True:
a, b = a + b, a
yield a
def nth(series, n):
'''
returns the nth element of a series,
consuming the series' earlier elements.
'''
for x in series:
n -= 1
if n <= 0: return x
print nth(fib(), 10)
/* not a comment and not keywords: null char true */
插入
注意:为了使公式内的下划线不被识别成强调,我们需要在前后加上反引号,使其成为代码段。多出来的code标签,我已调用程序在生成的html中删去。
上面的是行内公式,如果是行间公式的话,需要使用```math这种语言为math的代码区块,像这样:
接下来测试一些公式嵌套组合的情况:
| Syntax | 表头公式 |
|---|---|
| A1 | B1 |
| A2 | B2 |
blockquote中的公式
- list中的公式
- blockquote嵌套list
- 测试
测试标题中的公式
插入图片:
参考式图片与链接的方式一样。
自动链接(自动把网址转换成链接的形式):
markdown支持对于\`*_{}[]()#+-.!字符的转义输出
如果需要用到HTML标签,直接使用即可。
另外在网站里还放了一套表情包,测试一下
UPDATE: 把主博客与debug博客合并后,整体从自建静态博客整体迁移到了firekylin,增加了一些语法支持,具体如下。
这些是原生HTML标签:
- This is a subscript text
- This is a superscript text
- This is an underlined text
- 这是kbd标签示例(主题中优化了样式)Ctrl+C
- 这是ruby标签示例(主题中优化了样式):汉字、英雄
- 这是details标签(实现collapsed sections)示例
Tips for collapsed sections
You can add a header
You can add text within a collapsed section.
You can add an image or a code block, too.
puts "Hello World"
脚注功能:
Here is a simple footnote1.
A footnote can also have multiple lines2.
This is a second line.
Alert功能:
Note
Useful information that users should know, even when skimming content.
Tip
Helpful advice for doing things better or more easily.
Important
Key information users need to know to achieve their goal.
Warning
Urgent info that needs immediate user attention to avoid problems.
Caution
Advises about risks or negative outcomes of certain actions.
表格:
| Left-aligned | Center-aligned | Right-aligned |
|---|---|---|
| git status | git status | git status |
| git diff | git diff | git diff |
| Name | Character |
|---|---|
| Backtick | ` |
| Pipe | | |
| abc | def |
|---|---|
| bar | |
| bar | baz |
| abc | def |
|---|

欢迎留言