# 自动书签插件

**URL:** https://meta.discourse.org/t/auto-bookmarks-plugin/110250
**Category:** Plugin
**Created:** [2019年二月27日 16:20 UTC](https://meta.discourse.org/t/auto-bookmarks-plugin/110250 "2019-02-27T16:20:28Z")
**Posts on this page:** 1
**Showing post:** 9

<div class="post-metadata">

### Author: ![tobiaseigen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tobiaseigen/32/539204_2.png) [@tobiaseigen](https://meta.discourse.org/u/tobiaseigen)
#### Post date: [2019年三月5日 23:11 UTC](https://meta.discourse.org/t/auto-bookmarks-plugin/110250/9 "2019-03-05T23:11:08Z")

</div>

Nice work, @acaporrini! Thanks for contributing this nifty plugin. Is there any way you could envision adding a shortcode e.g. `[toc]` to generate a table of contents of headings and sub-headings within a post? This would make a [long term](https://meta.discourse.org/t/spec-table-of-contents/32248) [dream](https://meta.discourse.org/t/automatic-table-of-contents-generation/79626) a reality for me. ☁

> [@acaporrini](#):
>
> a small bookmark icon will appear:

I’m not sure this blue bookmark icon is really needed - it would be fine, in my view, for this to be a hidden feature that power users can use to deep link to sections within posts.

> [@acaporrini](#):
>
> ## Installation
> 
> Follow [Install a Plugin](https://meta.discourse.org/t/install-a-plugin/19157)  
> how-to from the official Discourse Meta, using `git clone https://github.com/acaporrini/auto-bookmarks.git`  
> as the plugin command.

Typo? Looks like this URL should be

```
https://github.com/acaporrini/discourse-auto-bookmarks.git

```

> [@pfaffman](#):
>
> That explains it. I mostly think that anyone who cares about the ability to link to headings would also bother to make them unique. It doesn’t seem that bad if a link goes the wrong place if someone is careless. That’s what HTML does, after all. (But maybe there’s something else I’m missing.)

I agree strongly with this. I would love to see this feature in core even without deduping anchors within posts. The benefits far outweigh the risks.

---

_[View the full topic](https://meta.discourse.org/t/auto-bookmarks-plugin/110250)._
