-
Notifications
You must be signed in to change notification settings - Fork 25.6k
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 sidebar nav instructions to documentation #476
Comments
Currently undocumented because I built it as a "one off" for the theme's documentation section. Wasn't really meant to be something as part of the theme as it's not the most straight forward thing to do. It involves manually listing out all of the links in a For example, the menu for the theme's documentation was built by:
# documentation links
docs:
- title: Getting Started
children:
- title: "Quick-Start Guide"
url: /docs/quick-start-guide/
- title: "Structure"
url: /docs/structure/
- title: "Installation"
url: /docs/installation/
- title: "Upgrading"
url: /docs/upgrading/
- title: Customization
children:
- title: "Configuration"
url: /docs/configuration/
- title: "Navigation"
url: /docs/navigation/
- title: "UI Text"
url: /docs/ui-text/
- title: "Authors"
url: /docs/authors/
- title: "Layouts"
url: /docs/layouts/
- title: Content
children:
- title: "Working with Posts"
url: /docs/posts/
- title: "Working with Pages"
url: /docs/pages/
- title: "Working with Collections"
url: /docs/collections/
- title: "Helpers"
url: /docs/helpers/
- title: "Utility Classes"
url: /docs/utility-classes/
- title: Extras
children:
- title: "Stylesheets"
url: /docs/stylesheets/
- title: "JavaScript"
url: /docs/javascript/
- title: Meta
children:
- title: "History"
url: /docs/history/
- title: "Contributing"
url: /docs/contributing/
- title: "Old 2.2 Docs"
url: /docs/docs-2-2/
- title: "License"
url: /docs/license/
- title: "Terms & Privacy Policy"
url: /terms/ And then in each sidebar:
nav: "docs" The better solution for adding the same YAML to multiple pages is with Front Matter Defaults in defaults:
# _docs
- scope:
path: ""
type: docs
values:
sidebar:
nav: "docs" |
Thanks a lot. I had figured out the part about I am making a minisite to accompany my recurrent neural network package which means adding a lot of documentation so this is perfect. |
Documentation has been added https://mmistakes.github.io/minimal-mistakes/docs/layouts/#custom-sidebar-navigation-menu |
very cool, thanks a lot! |
I just went through the documentation, I believe the step about making a collection is missing. |
@bquast Didn't include that as collection creation is a basic of using Jekyll that can be learned about from the official docs. |
Ok I agree. I guess I meant to say that people might not realise that the files need to a collection for the sidebar nav to work, maybe in a note or something. Or perhaps this is obvious to people who use jekyll more frequently than I do. |
Sidebar nav should work with posts and pages, not just collections. |
# sidebar 만들기 : mmistakes/minimal-mistakes#476
bundle update
.bundle exec jekyll build
.Environment informations
github-pages
Expected behavior
The text was updated successfully, but these errors were encountered: