Skip to content

Commit 7dbd234

Browse files
committed
Update docs
1 parent e407424 commit 7dbd234

File tree

1 file changed

+11
-20
lines changed

1 file changed

+11
-20
lines changed

docs/syntax/headings.md

Lines changed: 11 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Headings
22

3-
You can have up to 6 levels of headings. But only levels 2 and 3 are displayed in table of contents sidebar.
3+
You create a heading by adding number signs `#` in front of a word or phrase. The number of number signs you use should correspond to the heading level. For example, to create a heading level three `<h3>`, use three number signs (e.g., `### My Header`).
44

55
## Basics
66

@@ -20,18 +20,6 @@ You can have up to 6 levels of headings. But only levels 2 and 3 are displayed i
2020

2121
:::
2222

23-
:::{tab-item} HTML
24-
25-
```html
26-
<div class="heading-wrapper" id="heading-1">
27-
<h1>
28-
<a class="headerlink" href="#heading-1">Heading 1</a>
29-
</h1>
30-
</div>
31-
```
32-
33-
:::
34-
3523
:::{tab-item} Output
3624

3725
# Heading 1
@@ -61,48 +49,51 @@ You can have up to 6 levels of headings. But only levels 2 and 3 are displayed i
6149

6250
## Anchor Links
6351

64-
By default, the anchor links are generated based on the heading text. You can also specify a custom anchor link using the following syntax:
52+
By default, the anchor links are generated based on the heading text.
53+
You will get a hyphened, lowercase, alphanumeric version of any string you please, with any [diacritics](https://en.wikipedia.org/wiki/Diacritic) removed, whitespace and dashes collapsed, and whitespace trimmed.
6554

66-
### Default Anchor Link
55+
### Default Anchor Links
6756

6857
::::{tab-set}
6958

7059
:::{tab-item} Markdown
7160

7261
```markdown
7362

74-
## Hello-World
63+
#### Hello-World
7564

7665
```
7766

7867
:::
7968

8069
:::{tab-item} Output
8170

82-
## Hello-World
71+
#### Hello-World
8372

8473
:::
8574

8675
::::
8776

8877

89-
### Custom Anchor Link
78+
### Custom Anchor Links
79+
80+
You can also specify a custom anchor link using the following syntax.
9081

9182
::::{tab-set}
9283

9384
:::{tab-item} Markdown
9485

9586
```markdown
9687

97-
## Heading [#custom-anchor]
88+
#### Heading [#custom-anchor]
9889

9990
```
10091

10192
:::
10293

10394
:::{tab-item} Output
10495

105-
## Heading [#custom-anchor]
96+
#### Heading [#custom-anchor]
10697

10798
:::
10899

0 commit comments

Comments
 (0)