Download the PHP package stillat/statamic-bard-heading-permalinks without Composer
On this page you can find all versions of the php package stillat/statamic-bard-heading-permalinks. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package statamic-bard-heading-permalinks
Bard Heading Permalinks for Statamic
Bard Heading Permalinks is an addon for Statamic that can add permalinks automatically to headings, similar to how permalinks can be added to markdown content.
How to Install
To install Bard Heading Permalinks run the following command from the root of your project:
How to Use
Once installed you will need to register the Bard extensions provided by this addon. This is typically done within your site's AppServiceProvider
.
Bard Heading Permalinks provides two different extensions:
Permalink
: Responsible for rendering the embedded link within headingsHeadingPermalinkExtension
: Adds the permalink, and any other details to rendered headings
For convenience, both extensions may be registered at once:
Note: The
HeadingPermalinkExtension
will replace any existing heading extension.
Configuration
By default, Bard Heading Permalinks will utilize the heading_permalink
settings for the default markdown parser. For more information on configuring Statamic's markdown parsers, consider reading the official documentation here: https://statamic.dev/extending/markdown#configuration.
However, you may publish Bard Heading Permalink's configuration file to override any settings by running the following command from the root of your project:
A new file will be created at config/bard_permalinks.php
, with the following contents:
Bard Heading Permalinks supports all documented configuration options provided by CommonMark's Heading Permalink Extension. For more information on each configuration option, please consult their documentation page here: https://commonmark.thephpleague.com/2.4/extensions/heading-permalinks/.
License
Bard Heading Permalinks is free software, released under the MIT license.