* TOC as a separate output in non-standalone mode
@ 2020-04-20 17:13 R (Chandra) Chandrasekhar
[not found] ` <7dc74567-6adf-1a39-f4a7-c88b15763647-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: R (Chandra) Chandrasekhar @ 2020-04-20 17:13 UTC (permalink / raw)
To: pandoc-discuss
I am working on a website whose content is written in
pandoc-flavoured-markdown, and directly converted in non-standalone mode
to HTML5 for display.
I would like to export the table of contents by itself to populate a
sidebar distinct from the main content. Is there any way to generate the
TOC as a separate output?
Thanks.
Chandra
2020-04-20
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: TOC as a separate output in non-standalone mode
[not found] ` <7dc74567-6adf-1a39-f4a7-c88b15763647-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
@ 2020-04-20 18:28 ` BPJ
0 siblings, 0 replies; 2+ messages in thread
From: BPJ @ 2020-04-20 18:28 UTC (permalink / raw)
To: pandoc-discuss
[-- Attachment #1: Type: text/plain, Size: 1745 bytes --]
A file `toc-template.html` containing only
``````
$if(toc)$
<nav id="$idprefix$TOC" role="doc-toc">
$if(toc-title)$
<h2 id="$idprefix$toc-title">$toc-title$</h2>
$endif$
$table-of-contents$
</nav>
$endif$
``````
and then `--template=toc-template` on the command line or `template:
toc-template` in a defaults file ought to do the trick.
--
Better --help|less than helpless
Den mån 20 apr. 2020 19:14R (Chandra) Chandrasekhar <chyavana-Re5JQEeQqe8@public.gmane.orgm>
skrev:
> I am working on a website whose content is written in
> pandoc-flavoured-markdown, and directly converted in non-standalone mode
> to HTML5 for display.
>
> I would like to export the table of contents by itself to populate a
> sidebar distinct from the main content. Is there any way to generate the
> TOC as a separate output?
>
> Thanks.
>
> Chandra
> 2020-04-20
>
> --
> You received this message because you are subscribed to the Google Groups
> "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pandoc-discuss/7dc74567-6adf-1a39-f4a7-c88b15763647%40gmail.com
> .
>
--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CADAJKhCjSofWONngXJbP04wOQN12um02VJCm0zh-pkvG_BZDEQ%40mail.gmail.com.
[-- Attachment #2: Type: text/html, Size: 3059 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-04-20 18:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-20 17:13 TOC as a separate output in non-standalone mode R (Chandra) Chandrasekhar
[not found] ` <7dc74567-6adf-1a39-f4a7-c88b15763647-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2020-04-20 18:28 ` BPJ
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).