Skip to content

Is it possible to include several tables of contents within the same file? #2310

Answered by Dherse
eaxca1 asked this question in Q&A
Discussion options

You must be logged in to vote

My recommendation is to do the following:

#show heading.where(level: 1, outlined: true): it => [
  #it

  #set text(size: 12pt, weight: "regular")
  #outline(
      title: "Chapter outline",
      indent: true,
      target: heading
        .where(level: 1)
        .or(heading.where(level: 2))
        .after(it.location(), inclusive: true)
        .before(
          heading
            .where(level: 1, outlined: true)
            .after(it.location(), inclusive: false),
          inclusive: false,
        )
  )
]

Replies: 1 comment 3 replies

Comment options

Dherse
Oct 4, 2023
Collaborator Sponsor

You must be logged in to vote
3 replies
@Dherse
Comment options

Dherse Oct 4, 2023
Collaborator Sponsor

Answer selected by eaxca1
@eaxca1
Comment options

@Dherse
Comment options

Dherse Oct 4, 2023
Collaborator Sponsor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants