mataroa-blog / mataroa

Naked blogging platform
https://mataroa.blog
GNU Affero General Public License v3.0
256 stars 22 forks source link

Strikethrough text? #33

Open pratul opened 1 year ago

pratul commented 1 year ago

I tried the usual markdown syntax of surrounding text with ~~ but it doesn't seem to work. Does mataroa not support strikethrough formatted text?

sirodoht commented 1 year ago

Hey @pratul,

The markdown library we use (Python-Markdown) supports John Gruber’s markdown spec, which does not define strikethrough text.

We also use some extensions (fenced_code, tables, footnotes, toc) that are outside the spec but these are undocumented (on mataroa) and they might change.

I’ve found an extension for strikethrough text (from pymdownx / source) but I'm thinking to change the markdown library altogether to something else. Either mistletoe or mistune.

No specific timeline for this, though :)

ratsclub commented 2 months ago

I'm interested into using mistune as the markdown library. I really like its Directive approach! Although we would need to re-implement the syntax highlight theme.

@sirodoht Are you still interested on this?

sirodoht commented 2 months ago

Sure, yes! Feel free to work on it :)

ratsclub commented 2 months ago

Okay, from my investigation mistletoe would require use to write a bunch of extensions... I don't think this is productive given that we already have most of them here.

On the other side, mistune would only need a new footnotes plugin as it doesn't add a <hr/> tag. What do you think? Should we add the strikethrough extension to our current markdown library or migrate to mistune and write the footnotes (basically copying and pasting the official one, but adding a <hr/> tag)?

sirodoht commented 2 months ago

I like mistune more but haven't done a deep look into it, so cannot say much.