Skip to content

Commit

Permalink
Add 'Link Prefix' on README
Browse files Browse the repository at this point in the history
  • Loading branch information
naokazuterada committed Sep 30, 2017
1 parent e1d5df6 commit 4cef904
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ Sublime Text 3 plugin for generating a Table of Contents (TOC) in a Markdown doc
- [Manipulation of auto link ids](#manipulation-of-auto-link-ids)
- [URI encoding](#uri-encoding)
- [Markdown Preview compatible](#markdown-preview-compatible)
- [Link Prefix](#link-prefix)
- [Control of depth listed in TOC](#control-of-depth-listed-in-toc)
- [Ordered or unordered style for TOC elements](#ordered-or-unordered-style-for-toc-elements)
- [Customizable list bullets in TOC](#customizable-list-bullets-in-toc)
Expand Down Expand Up @@ -82,6 +83,7 @@ The **MarkdownTOC** plugin is rich on features and customization, useful for bot
- Ordered or unordered style for TOC elements
- Customizable list bullets in TOC
- Specify custom indentation prefix
- Customizable link prefix

### Insertion of TOC based on headings in Markdown document

Expand Down Expand Up @@ -464,6 +466,22 @@ Currently no other parsers are supported.
If you want to disable this feature, set it to `false`.


#### Link Prefix

You can also set _prefix_ of links.

```markdown
<!-- MarkdownTOC autolink=true link_prefix="user-content-" -->

- [My Heading][user-content-my-heading]

<!-- /MarkdownTOC -->

# My Heading
```

You can manipulate this in your [configuration](#configuration) using the key `default_link_prefix`.

### Control of depth listed in TOC

```markdown
Expand Down Expand Up @@ -743,6 +761,7 @@ The following attributes can be used to control the generation of the TOC.
| `depth` | integer (`0` means _no limit_) | `2` | `default_depth` |
| `indent` | string | `"\t"` | `default_indent` |
| `link_prefix` | string | `""` | `default_link_prefix` |
| `list_bullets` | string | `"-"` | `default_list_bullets` |
| `lowercase` | `true`or`false` | `true` | `default_lowercase` |
| `lowercase_only_ascii` | `true`or`false` | `true` | `default_lowercase_only_ascii` |
| `remove_image` | `true`or`false` | `true` | `default_remove_image` |
Expand Down Expand Up @@ -790,6 +809,7 @@ Example: `MarkdownTOC.sublime-settings`
"default_bracket": "square",
"default_depth": 2,
"default_indent": "\t",
"default_link_prefix": "",
"default_list_bullets": "-",
"default_lowercase": true,
"default_lowercase_only_ascii": true,
Expand Down Expand Up @@ -819,6 +839,7 @@ For an overview of the specific behaviour behind an attribute, please refer to t
- `default_bracket`, (see: [Auto linking for _clickable_ TOC](#auto-linking-for-clickable-toc))
- `default_depth`, (see: [Control of depth listed in TOC](#control-of-depth-listed-in-toc))
- `default_indent`, (see: [Specify custom indentation prefix](#specify-custom-indentation-prefix))
- `default_link_prefix`, (see: [Link Prefix](#link-prefix))
- `default_list_bullets`, (see: [Customizable list bullets in TOC](#customizable-list-bullets-in-toc))
- `default_lowercase`, (see: [Preserve case](#preserve-case))
- `default_lowercase_only_ascii`, (see: [Lowercase only ASCII characters in auto link ids](#lowercase-only-ascii-characters-in-auto-link-ids))
Expand Down

0 comments on commit 4cef904

Please sign in to comment.