Skip to main content

Custom heading IDs for Foliant.

Project description

# СustomIDs

CustomIDs is a preprocessor that allows to define custom identifiers (IDs) for headings in Markdown source by using Pandoc-style syntax in projects built with MkDocs. These IDs may be used in hyperlinks that refer to a specific part of a page.

## Installation

$ pip install foliantcontrib.customids

## Usage

To enable the preprocessor, add `customids` to `preprocessors` section in the project config:

- customids

Custom ID may be specified after a heading content at the same line. Examples of Markdown syntax:

# Heading 1 {#custom_id_for_first_heading}

A paragraph.

## Heading 2 {#custom_id_for_second_heading}

Some another paragraph.

Custom IDs must not contain spaces and non-ASCII characters.

Examples of hyperlinks that refer to custom IDs:

[Link to Heading 1](#custom_id_for_first_heading)

[Link to Heading 2 in some document at the current site](/some/page/#custom_id_for_second_heading)

[Link to some heading with custom ID at an external site](

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

foliantcontrib.customids-1.0.2.tar.gz (2.4 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page