YuChenSUN Blog
主要特性
- 支持“标准”markdown / commonmark和github风格的语法,也可变身为代码编辑器;
- 支持实时预览、图片(跨域)上传、预格式文本/代码/表格插入、代码折叠、搜索替换、只读模式、自定义样式主题和多语言语法高亮等功能;
- 支持toc(table of contents)、emoji表情、task lists、@链接等markdown扩展语法;
- 支持tex科学公式(基于katex)、流程图 flowchart 和 时序图 sequence diagram;
- 支持识别和解析html标签,并且支持自定义过滤标签解析,具有可靠的安全性和几乎无限的扩展性;
- 支持 amd / cmd 模块化加载(支持 require.js & sea.js),并且支持自定义扩展插件;
- 兼容主流的浏览器(ie8+)和zepto.js,且支持ipad等平板设备;
- 支持自定义主题样式;
editor.md






目录 (table of contents)
[tocm]
[toc]
heading 1
heading 2
heading 3
heading 4
heading 5
heading 6
heading 1 link heading link
heading 2 link heading link
heading 3 link heading link
heading 4 link heading link heading link heading link
heading 5 link heading link
heading 6 link heading link
标题(用底线的形式)heading (underline)
this is an h1
this is an h2
字符效果和横线等
删除线 删除线(开启识别html标签时)
斜体字 斜体字
粗体 粗体
粗斜体 粗斜体
上标:x2,下标:o2
缩写(同html的abbr标签)
即更长的单词或短语的缩写形式,前提是开启识别html标签时,已默认开启
the html specification is maintained by the w3c.
引用 blockquotes
引用文本 blockquotes
引用的行内混合 blockquotes
引用:如果想要插入空白换行
即<br />标签,在插入处先键入两个以上的空格然后回车即可,普通链接。
锚点与链接 links
直接链接:https://github.com
gfm a-tail link @pandao
@pandao
多语言代码高亮 codes
行内代码 inline code
执行命令:npm install marked
缩进风格
即缩进四个空格,也做为实现类似<pre>预格式化文本(preformatted text)的功能。
<?php
echo "hello world!";
?>
预格式化文本:
| first header | second header |
| ------------- | ------------- |
| content cell | content cell |
| content cell | content cell |
js代码
1 | |
html代码 html codes
1 | |
图片 images
image:

follow your heart.

图为:厦门白城沙滩
图片加链接 (image + link):
图为:李健首张专辑《似水流年》封面
列表 lists
无序列表(减号)unordered lists (-)
- 列表一
- 列表二
- 列表三
无序列表(星号)unordered lists (*)
- 列表一
- 列表二
- 列表三
无序列表(加号和嵌套)unordered lists (+)
- 列表一
- 列表二
- 列表二-1
- 列表二-2
- 列表二-3
- 列表三
- 列表一
- 列表二
- 列表三
有序列表 ordered lists (-)
- 第一行
- 第二行
- 第三行
gfm task list
- [x] gfm task list 1
- [x] gfm task list 2
- [ ] gfm task list 3
- [ ] gfm task list 3-1
- [ ] gfm task list 3-2
- [ ] gfm task list 3-3
- [ ] gfm task list 4
- [ ] gfm task list 4-1
- [ ] gfm task list 4-2
绘制表格 tables
| 项目 | 价格 | 数量 |
|---|---|---|
| 计算机 | $1600 | 5 |
| 手机 | $12 | 12 |
| 管线 | $1 | 234 |
| first header | second header |
|---|---|
| content cell | content cell |
| content cell | content cell |
| first header | second header |
|---|---|
| content cell | content cell |
| content cell | content cell |
| function name | description |
|---|---|
help() |
display the help window. |
destroy() |
destroy your computer! |
| left-aligned | center aligned | right aligned |
|---|---|---|
| col 3 is | some wordy text | $1600 |
| col 2 is | centered | $12 |
| zebra stripes | are neat | $1 |
| item | value |
|---|---|
| computer | $1600 |
| phone | $12 |
| pipe | $1 |
特殊符号 html entities codes
© & ¨ ™ ¡ £
& < > ¥ € ® ± ¶ § ¦ ¯ « ·
x² y³ ¾ ¼ × ÷ »
18ºc " '
emoji表情 :smiley:
blockquotes :star:
gfm task lists & emoji & fontawesome icon emoji & editormd logo emoji :editormd-logo-5x:
- [x] :smiley: @mentions, :smiley: #refs, links, formatting, and
tagssupported :editormd-logo:; - [x] list syntax required (any unordered or ordered list supported) :editormd-logo-3x:;
- [x] [ ] :smiley: this is a complete item :smiley:;
- [ ] []this is an incomplete item test link :fa-star: @pandao;
- [ ] [ ]this is an incomplete item :fa-star: :fa-gear:;
反斜杠 escape
*literal asterisks*
科学公式 tex(katex)
$$e=mc^2$$
行内的公式$$e=mc^2$$行内的公式,行内的$$e=mc^2$$公式。
$$(\sqrt{3x-1}+(1+x)^2)$$
$$\sin(\alpha)^{\theta}=\sum_{i=0}^{n}(x^i + \cos(f))$$
多行公式:
1 | |
1 | |
1 | |
绘制流程图 flowchart
1 | |
绘制序列图 sequence diagram
1 | |
end
YuChenSUN Blog
https://sunblog.yuchen.icu/2023/10/14/hello-world/
