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

自定义Toc.vue的标题 #85

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

自定义Toc.vue的标题 #85

wants to merge 2 commits into from

Conversation

0xlau
Copy link

@0xlau 0xlau commented Dec 14, 2022

允许自定义Toc.vue的标题

允许自定义Toc.vue的标题
@ulivz
Copy link
Owner

ulivz commented Feb 3, 2023

Thanks for your contribution, could you help write a documentation for this feature?

@vercel
Copy link

vercel bot commented Mar 29, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated
vuepress-docs ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Mar 29, 2023 at 4:37AM (UTC)

@0xlau
Copy link
Author

0xlau commented Mar 29, 2023

image

Here are two ways to modify the toc title:

  1. Declare with Frontmatter:
---
tocTitle: ON THIS PAGE
---
  1. Via the themeConfig property
// .vuepress/config.js
module.exports = {
  theme: "vt",
  themeConfig: {
    tocTitle: "ON THIS PAGE"
  },
};

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.

2 participants