Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: use top 2 level of nodes to generate toc #757

Merged
merged 3 commits into from
Feb 10, 2021
Merged

Conversation

farnabaz
Copy link
Member

@farnabaz farnabaz commented Feb 9, 2021

Types of changes

  • Bug fix (a non-breaking change which fixes an issue)
  • New feature (a non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Description

Currently Nuxt Content uses only top level elements to generate table of content therefore TOC will not generate for documents which wrapped inside a tag.

Originally issued here: https://www.github.com/nuxtlabs/docus/issues/21#issuecomment-776078940

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes (if not applicable, please state why)

Copy link
Member

atinux commented Feb 9, 2021

Do you mind adding a test to avoid any regression in the future?
https://github.com/nuxt/content/tree/dev/packages/content/test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants