编码风格指南
标题
# Heading h1
## Heading h2
### Heading h3
#### Heading h4
##### Heading h5
###### Heading h6
注意:h1 – h4 项目将自动添加到目录中。
强调
斜体字
_
对于_斜体_文本,用单个换行文本:
This is _italic text_.
大胆的
粗体**
文本用双倍换行:
This is **bold text**.
删除线
为 ~~ 删除线 ~~ 文字换行文字~~
:
This is ~~strikethrough~~ text.
链接
将标题放在方括号中,[title]
紧跟在 URL 之后(https://example.com)
:
[WordPress](https://wordpress.org/)
块引用
用于>
块引号,加倍>>
以进一步缩进:
> Blockquote
>> Indented Blockquote
列表
无序列表
用于-
无序列表,并为列表子项指定两个空格:
- List
- List
- List
- List
有序列表
使用带编号的项目后跟 `.:
1. One
2. Two
3. Three
横线
用于---
水平规则:
---
表
| A | B |
| ----- | ----- |
| Alpha | Bravo |
var foo = function (bar) {
return bar++;
};
console.log(foo(5));
JSON
{
"firstName": "John",
"lastName": "Smith",
"address": {
"streetAddress": "21 2nd Street",
"city": "New York",
"state": "NY",
"postalCode": "10021-3100"
},
"phoneNumbers": [
{
"type": "home",
"number": "212 555-1234"
},
{
"type": "office",
"number": "646 555-4567"
}
],
"children": [],
"spouse": null
}
CSS
foo {
padding: 5px;
margin-right: 3px;
}
.bar {
background-color: #f00;
}
SCSS
foo {
padding: 5px;
margin-right: 3px;
}
.bar {
background-color: #f00;
}
HTML
<span class="my-class">Example</span>
PHP
$array = array(
"foo" => "bar",
"bar" => "foo",
);
编码
This is _italic text_. This is **bold text**.