Replies: 1 comment 1 reply
-
Hey Alexander! For reference, the output HTML: <details><summary>Tap to reveal</summary>
# Boo!
</details> Cool. This sounds like a good use case for a micromark extension :) But yes, it’s very tough to get into extension development. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there! I am building an app for Lemmy.
Lemmy uses a custom spoiler format, in the form of:
Which transforms to
Tap to reveal
Boo!
As for why I am building a micromark plugin, it's because I have no other choice. I can't change the markdown format, because I don't control the Lemmy project. I just build an app for it. So I can't force lemmy to adopt a format that works with micromark-directive, for example. Therefore, I'm trying to fork micromark-directive to work with this format. I've had some modest success, but I'm currently stuck where I run
DEBUG="micromark" npm test
and the parser gets stuck. I'm not sure how to debug this. It appears as if the parser calls the finalok()
though.I've simplified the app so there's a single test case, so just
npm i
andDEBUG="micromark" npm test
should see the issue.Here's the repo, if you have a moment: https://github.com/aeharding/micromark-extension-lemmy-spoiler
P.S. The app I'm trying to get this working for is FOSS! It's called Voyager. This is Voyager's second most requested open feature; I've just had a really hard time getting this working despite multiple attempts at forking remark-directive over the last few weeks (I learn a bit each time). Any help is VERY appreciated. ❤️
Beta Was this translation helpful? Give feedback.
All reactions