mirror of
https://github.com/xoofx/markdig.git
synced 2026-02-10 21:40:00 +00:00
AutoIdentifierOptions.GitHub should remove dots from anchor links #198
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Jeavon on GitHub (Mar 9, 2018).
On GitHub
### Thing (v7.7.3+)produces a anchor of#thing-v773However when using markdig we get a anchor of
#thing-v7.7.3So when AutoIdentifierOptions.GitHub is used the dots should be removed from the anchors
@xoofx commented on GitHub (Mar 9, 2018):
this should be removed (typically all the links at scriban were generated with Markdig) and looking at the markdig code:
964538ec79/src/Markdig/Helpers/LinkHelper.cs (L100-L115)it does keep only letter, digit,
-,_but I don't see any.So not sure exactly how did you get your result?
@Jeavon commented on GitHub (Mar 9, 2018):
@xoofx I'm not sure if I'm doing something wrong then, perhaps the attached helps?

@Jeavon commented on GitHub (Mar 9, 2018):
Checked we weren't doing anything to the heading before passing into Markdig
@xoofx commented on GitHub (Mar 9, 2018):
UseAdvancedExtensions().UseAutoIdentifiers(...)will not work as the extension is already added byUseAdvancedExtensions. Try to issue theUseAutoIdentifiersbefore@Jeavon commented on GitHub (Mar 9, 2018):
That's got it, thanks so much @xoofx !