【发布时间】:2016-10-26 11:46:52
【问题描述】:
如何将 CSS 添加到 github 的 markdown 语言中?
我已经能够通过在 html 标签中使用 style 属性来做到这一点,例如:
<p style="text-align: center;">This is some random text</p>
但如果我将 css 移到开头,例如:
<style>
p {
text-align: center;
}
</style>
<p>This is some random text</p>
Github 无法识别,只是将 css 代码写入屏幕。
我正在使用 Atom,并且 Markdown Preview 包实际上可以正确识别这一点,即使在远程存储库上它显示错误。 Google Chrome 扩展 Markdown Preview Plus 也是如此。
有没有办法做到这一点?在 html 标签中写 css 感觉完全不对。
【问题讨论】:
标签: css github-flavored-markdown