package blackfriday

import "github.com/gohugoio/hugo/markup/blackfriday"

Package blackfriday holds some compatibility functions for the old Blackfriday v1 Markdown engine.

Index

Functions

func SanitizedAnchorName

func SanitizedAnchorName(text string) string

SanitizedAnchorName is how Blackfriday sanitizes anchor names. Implementation borrowed from https://github.com/russross/blackfriday/blob/a477dd1646916742841ed20379f941cfa6c5bb6f/block.go#L1464 Note that Hugo removed its Blackfriday support in v0.100.0, but you can still use this strategy for auto ID generation.

Source Files

anchors.go

Version
v0.144.2 (latest)
Published
Feb 19, 2025
Platform
linux/amd64
Imports
1 packages
Last checked
13 hours ago

Tools for package owners.