markdown语法
Posted sna-ling
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了markdown语法相关的知识,希望对你有一定的参考价值。
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>JS Bin</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/marked/0.7.0/marked.js"></script>
</head>
<body>
<div id="content"></div>
<script>
var markdown=`
# Marked in the browser
## Rendered by **marked**.
[百度](http://baidu.com)
`
var html= marked(markdown);
document.getElementById(‘content‘).innerHTML =html;
</script>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>JS Bin</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/marked/0.7.0/marked.js"></script>
</head>
<body>
<div id="content"></div>
<script>
var markdown=`
# 我的第一遍博客
**小凌**
>不要相信网上的名人名言。——鲁迅
大家好我今天学会了markdown语法了。

`
var html= marked(markdown);
document.getElementById(‘content‘).innerHTML =html;
</script>
</body>
以上是关于markdown语法的主要内容,如果未能解决你的问题,请参考以下文章