artempyanykh / marksman

Write Markdown with code assist and intelligence in the comfort of your favourite editor.
MIT License
1.98k stars 35 forks source link

Configurable headline slug generation #244

Closed codingluke closed 1 year ago

codingluke commented 1 year ago

Dear marksman team, Thank you very much for your effort. Because of projects like this, neovim gets from year to year better to work with :)

I just encountered something using docusaurus.io and marksman together. In docusarurus it is possible to add emojis with the :smiley: syntax.

Given a title # :smiley: This is a friendly header, docusaurus sripes out the whole :smiley: part. The anchor-slug will be #-this-is-a-friendly-header. On the other hand marksman is only removing the special chars and ends up with #smiley-this-is-a-friendly-header.

At the end of the day I can choose of a not working link or a shouting marksman linter ;) There are two ways to fix this:

  1. Docusaurus is changing the heading-slug generation (or gives the possibility to change it)
  2. Marksman is changing the heading-slug generation (or gives the possibility to change it)

In my opinion, as marksman is kind of meta, the configuration should be possible here, what do you think?

Best Codingluke

codingluke commented 1 year ago

closed as docusaurus is seeing this as a bug an will adapt their slugifying mechanism. Thanks to marksmans linter I found this :)

artempyanykh commented 1 year ago

Thanks for the kind words @codingluke! And happy to hear that the problem is going to be resolved on the docusaurus end.