The Dead Simple Markdown Guide to Horizontal Rules
2024-8-20 23:49:41 Author: hackernoon.com(查看原文) 阅读量:4 收藏

Read on Terminal Reader

Read this story w/o Javascript

Open TLDRtldt arrow

Too Long; Didn't Read

Create horizontal rules in Markdown using three or more asterisks (***), dashes (---), or underscores (___). Ensure blank lines are placed before and after the rule for compatibility.

featured image - The Dead Simple Markdown Guide to Horizontal Rules

Typesetting HackerNoon profile picture

Horizontal Rules

To create a horizontal rule, use three or more asterisks (***), dashes (---), or underscores (___) on a line by themselves.

***

---

_________________

The rendered output of all three looks identical:

Horizontal Rule Best Practices

For compatibility, put blank lines before and after horizontal rules.

✅  Do this

❌  Don't do this

Try to put a blank line before...

---

...and after a horizontal rule.

Without blank lines, this would be a heading.
---
Don't do this!

This guide is a Matt Cone project available on Markdown Guide under the CC BY-SA 4.0 license.


文章来源: https://hackernoon.com/the-dead-simple-markdown-guide-to-horizontal-rules?source=rss
如有侵权请联系:admin#unsafe.sh