-
-
Notifications
You must be signed in to change notification settings - Fork 739
feat(search): add minHeading/maxHeading options #3636
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
Conversation
|
@onmax is attempting to deploy a commit to the Nuxt Team on Vercel. A member of the Team first needs to authorize it. |
commit: |
|
I like the idea about separator but I'm not sure how useful it could be because by default other elements do not have |
|
Good point. In my personal needs, the main use case is customising which heading levels trigger a new section (e.g. 'h2' or 'h3' rather than all headings). Adding support for any component, like Should I add a note about this in the documentation, or should we only allow headings in the separator option? |
|
I think headers should be enough. Let’s face it: if you want to create a section, you need a title. What’s the purpose of a section without a title and proper link? In my view, if it doesn’t have a title, it’s most likely a continuation of the previous section. So I'll go with headers only option. |
8b0ede9 to
3c0b97e
Compare
|
updated the pr. changed api from the array approach allowed weird combos like |
farnabaz
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Thanks
Adds
minHeadingandmaxHeadingoptions to filter which heading levels create new sections.Default:
h1toh6(backward compatible)