StangSpree
StangSpree

Reputation: 439

Adding new tab to Docusaurus v2 navbar

I'm trying to add a new item to navbar using Docusaurus v2. I have added an item 'Releases' next to blog in the same way as 'Blog' is added. I also created a new directory 'releases' with a .md file in it. Navbar displays the new tab but does not render the contents. It loads 'page not found' template. Am I missing any additional configuration?

navbar: {
      title: "App",
      logo: {
        alt: "Logo",
        src: "img/logo.svg"
      },
      links: [
        {
          to: "docs/",
          activeBasePath: "docs",
          label: "Docs",
          position: "left"
        },
        { to: "blog", label: "Blog", position: "left" },
        { to: "releases", label: "Releases", position: "left" },
        {
          href: "",
          label: "Github",
          position: "right"
        }
      ]
    }

Upvotes: 3

Views: 4550

Answers (1)

Yangshun Tay
Yangshun Tay

Reputation: 53219

You need to create your new page under pages/releases.js. This is not a doc or blog page, so Markdown won't be supported.

Upvotes: 2

Related Questions