Looking to organize and order content within a Guru Card? At this time, Guru does not have a table of contents tool built into the Card editor. We encourage you to try and keep your Card content short and to the point. However, we certainly understand that not all content can be published in a short-form fashion. This article contains a workaround to create a table of contents with anchor text.


๐Ÿ’ก Tip

We suggest using our Card-to-Card linking feature, which will allow you to direct your users to other Guru Cards in a similar way that anchoring does. Read more about Card-to-Card linking.


What is anchor text?

The Markdown tool allows you to create anchor text which can act as a "table of contents" in a Guru Card. Anchor text allows you to set up content at the top of a Card that links to headings throughout the Card so readers can find the information they need even faster.


โœ๏ธ Note

Because anchor text is a workaround and not a Guru feature, there are some limitations to this path. Namely, we've seen some cases where this advice doesn't work as expected over other websites when a Card containing anchor text is opened through the Guru browser extension. Anchor links will also fail to function as expected if there are typos or extra spaces in the Markdown blocks.


Creating a table of contents with anchor text in a Card

Step 1: Set link text in the format of a table of contents

1. As a Collection Owner or Author, create a Card or edit an existing Card. Click in the body of the Card where you would like to insert a table of contents and insert a Markdown block.

2. Type the following code into the Markdown block:

<a href="#referenceword">Text the user will see</a> 

3. Replace Text the user will see with the title of the text that you want to appear in your table of contents and #referenceword with a reference to the title, as shown in the image below. The title of the text is what the user will click to "jump" to a specific location in the Guru Card.

4. Repeat steps #2-3 in the Markdown block until the table of contents is complete.

Step 2: Set corresponding anchors in the body of the Card

1. Scroll the Card to the place you would like the user to "jump" to when clicking the first anchor link and insert a Markdown block.

2. Type the following code into the Markdown block, using the same exact reference text that corresponds with the text you typed for the top Markdown block:

 <a name="referenceword"></a> 

3. Repeat steps 1 and 2 until each link in the table of contents has a corresponding anchor markdown block in the body of the Card.

4. Publish the Card. After publishing, the text in the top Markdown block will be hyperlinked. Clicking the hyperlinked text will scroll the user to the area where the corresponding anchor is located.


๐Ÿ’กTip

Here is an example to a Public Card that shows a table of contents with the Markdown block visible below each step of the process.


Guru on Guru Example

Watch how we create anchor texts, table of contents, and bookmarks in our Guru Cards.

Note: this video reflects an earlier version of Guru's Card editor.


๐Ÿก Check this out in the Guru Community
Show your support for the table of contents feature request by giving this post in our Community an upvote.


๐Ÿ“‘ Related articles


Did this answer your question?