Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions fern/products/docs/pages/navigation/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ description: Set up the navigation for your documentation site built with Fern D

Every Fern Docs website has a special configuration file called `docs.yml`. Use this file to configure the navigation for your documentation site.

test

Here's a complete example of a `docs.yml` file:

<CodeBlock title="An example docs.yml">
Expand Down Expand Up @@ -99,6 +101,7 @@ For the pages in a folder, Fern automatically converts filenames to titles and U
To hide a page, folder, or section, add `hidden: true`. Hidden content (including all pages within a folder) is still accessible via direct URL but is excluded from search and won't be indexed.

{/* <!-- vale off --> */}

```yaml docs.yml {7, 10, 12}
navigation:
- section: Introduction
Expand All @@ -117,6 +120,7 @@ navigation:
- page: Another hidden page
path: ./pages/also-hidden.mdx
```

{/* <!-- vale on --> */}

## Availability
Expand All @@ -141,6 +145,7 @@ navigation:
title: Performance monitoring
availability: in-development # Overrides section-level availability
```

<Note>
If you have different versions of your docs, section, folder, and page availability should be set in [the `.yml` files that define the navigational structure for each version](/learn/docs/configuration/versions#define-your-versions).
</Note>
Expand Down Expand Up @@ -170,6 +175,7 @@ navigation:
To add an overview page to a section, add a `path` property to the section.

{/* <!-- vale off --> */}

```yaml Example section with an overview {7}
navigation:
- section: Introduction
Expand All @@ -184,6 +190,7 @@ navigation:
- page: Complex guide
path: ./pages/guides/complex.mdx
```

{/* <!-- vale on --> */}

## Nested sections
Expand Down Expand Up @@ -244,6 +251,7 @@ Add icons next to sections, pages, and folders using the `icon` key.
<Markdown src="/snippets/icons.mdx" />

{/* <!-- vale off --> */}

```yaml Example config with different icon files {3, 6, 10-11, 14}
navigation:
- section: Home
Expand All @@ -259,13 +267,15 @@ navigation:
- api: API Reference
icon: fa-regular fa-puzzle
```

{/* <!-- vale on --> */}

## Links

You can add a link to an external page within your sidebar navigation with the following configuration:

{/* <!-- vale off --> */}

```yaml title="docs.yml"
navigation:
- section: Home
Expand All @@ -275,6 +285,7 @@ navigation:
- link: Our YouTube channel
href: https://www.youtube.com/
```

{/* <!-- vale on --> */}

<Frame>
Expand Down