menu
Last updated
Last updated
Website header navigation menu, if you need to add a new navigation menu, fill in the above format, also need to create the corresponding Hexo page.
The Hexo project does not have pages such as categories (categories), tags (tags), about (about), and links (friendship chains), which need to be created manually.
Take creating an "about" page as an example:
Execute the command hexo new page about
in the root directory of the Hexo project to generate the about folder in the source
directory.
Add About: /about
under the menu
configuration item in the Redefine theme configuration file _config.redefine.yml
.
Among them, the front About
is the name displayed on the home page, and the latter /about
is the page path
Open the /source/about/index.md
file under the Hexo project and fill in the content of the about page. Supports Markdown and HTML formats;
The reference is as follows:
::: tip comment: true
means that the page enables the comment function. :::
::: danger Do not modify the title
attribute that is automatically generated when the page is created! Do not delete it! For example: title: about
cannot be modified! :::
If you want to jump to a third-party website when you click the menu in the navigation bar, you only need to fill in the value of the configuration item as the URL of the third-party website. For example: configure to go to Google in the header navigation bar