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

[WIP] feat: markdown.extractHeaders option #1730

Closed

Conversation

ulivz
Copy link
Member

@ulivz ulivz commented Jul 30, 2019

Summary

Fix #1903

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Docs
  • Build-related changes
  • Other, please describe:
module.exports = {
  markdown: {
    extractHeaders: ['h2', 'h3', 'h4'] // defaults to ['h2', 'h3'] 
  }
}

Replacement of #1111

If changing the UI of default theme, please provide the before/after screenshot:

Does this PR introduce a breaking change? (check one)

  • Yes
  • No

If yes, please describe the impact and migration path for existing applications:

The PR fulfills these requirements:

  • When resolving a specific issue, it's referenced in the PR's title (e.g. fix #xxx[,#xxx], where "xxx" is the issue number)

You have tested in the following browsers: (Providing a detailed version will be better.)

  • Chrome
  • Firefox
  • Safari
  • Edge
  • IE

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature
  • Related documents have been updated
  • Related tests have been updated

To avoid wasting your time, it's best to open a feature request issue first and wait for approval before working on it.

Other information:

This is my 1st work with Gitpod

@ulivz ulivz self-assigned this Jul 30, 2019
@ulivz ulivz changed the title feat: markdown.extractHeaders option [WIP] feat: markdown.extractHeaders option Jul 30, 2019
@flozero flozero added contribution welcome Contributions welcome topic: config Relates to VuePress config topic: markdown Relates to VuePress markdown type: enhancement Request to enhance an existing feature version: 1.x Relates to version 1 of VuePress labels Sep 5, 2019
@funnycoderstar
Copy link

This is exactly what I want.

@ulivz
Copy link
Member Author

ulivz commented Oct 11, 2019

Issue of this pull request is that sidebar of VuePress doesn't support infinite nesting. even we extract more headers, extra headers will not be indented, which would be considered as a new issue.

Maybe we need to fix the indent problem before getting this pull request merged.

// cc @kefranabg @f3ltron

@kefranabg kefranabg added status: WIP Work in progress and removed contribution welcome Contributions welcome topic: config Relates to VuePress config topic: markdown Relates to VuePress markdown type: enhancement Request to enhance an existing feature version: 1.x Relates to version 1 of VuePress labels Oct 12, 2019
@kefranabg
Copy link
Collaborator

kefranabg commented Oct 12, 2019

Seems like I do not have rights to push on this PR 🤔 @funnycoderstar could you enable authors commits on your fork?

@kefranabg
Copy link
Collaborator

Close this PR in favor of #1945 as I'm not able to update this one.

@kefranabg kefranabg closed this Oct 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: WIP Work in progress
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot access page headers that are not h2 or h3
5 participants