2

I am using slate, https://github.com/lord/slate, for API documentation. Using slate, a markdown file is converted to HTML. I need to have collapsable sections in my final HTML page. I appreciate if you let me know about the best approach?

Pooneh
  • 67
  • 2
  • 10
  • Collapsing regions require either scripting or a `:checked` style with hidden `` elements - both of which are dependent on the context the Markdown-generated HTML is being rendered into. This is not something built-in to Markdown at all. – Dai Jul 14 '17 at 17:35
  • 1
    Stack Overflow isn't a code-writing service. [Do some research](https://meta.stackoverflow.com/q/261592/497418) and when you've got a real question, feel free to ask it here. Until then, if you have a work order, go hire a developer. – zzzzBov Jul 14 '17 at 17:39

1 Answers1

1

As far as I'm aware, markdown or slate don't support this directly. One option could be to mix the <summary> and <details> html tags in with your markdown, but then you'd have to style it yourself to match slate's style.

Michael
  • 26
  • 2