-
-
Notifications
You must be signed in to change notification settings - Fork 52
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
Add an ignore_within
option
#53
Conversation
@DEfusion Thanks for sending PR 😍 In the version v0.7.0.alpha1, |
The <h2>Titles</h2>
<div class="example">
<h1 class="title">Title</h1>
<h2 class="subtitle">Subtitle</h2>
</div>
<h2>Sections</h2>
<div class="example">
<div class="section">
<h1 class="title">Title</h1>
...
</div>
</div> So I'd rather automatically exclude all headings from the toc rather than having to add the |
@DEfusion That makes sense, having ignore section would be useful. Could you rebase the PR to fix conflict? |
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.
Fixing conflict is needed 💥
Adds an `ignore_within` option to provide a selector to ignore elements within. So given the following HTML: ```html <h1>h1</h1> <div class="exclude"> <h2>h2</h2> <h3>h3</h3> </div> <h4>h4</h4> ``` With the configuration: ```yml toc: ignore_within: .exclude ``` All headings within the `.exclude` selector will be ignored.
@toshimaru rebased, no conflicts now. |
@DEfusion Thanks, let's get this merged. |
v0.8.0.beta1 released. :) |
Add an `ignore_within` option
Adds an
ignore_within
option to provide a selector to ignore elements within. So given the following HTML:With the configuration:
All headings within the
.exclude
selector will be ignored.