Skip to content

Conversation

@devin-ai-integration
Copy link
Contributor

Document folder-based navigation configuration

Summary

This PR adds comprehensive documentation for the folder-based navigation feature that allows users to automatically generate navigation from a folder of markdown files instead of manually listing each page in docs.yml.

Changes:

  • Added new documentation page: fern/products/docs/pages/navigation/folder-based-navigation.mdx (259 lines)
  • Updated fern/products/docs/docs.yml to include the new page in the Configuration section, positioned after "Navigation"

What the documentation covers:

  • Basic usage with simple examples
  • How the feature works (file discovery, title/slug generation, sorting, nested folders)
  • All configuration options: title, slug, icon, collapsed, hidden, skip-slug, availability
  • Combining folder-based and manual navigation
  • Controlling page order with frontmatter position field
  • Use cases and real-world example from Slack

Review & Testing Checklist for Human

⚠️ Critical items to verify (in order of importance):

  • Test the folder configuration feature - Create a test docs project with a folder of markdown files and verify the feature actually works as documented. Key things to test:

    • Does it discover all .md and .mdx files?
    • Are titles and slugs generated correctly from filenames?
    • Do nested folders create nested sections?
    • Do all the configuration options (especially skip-slug, availability, collapsed) work as documented?
  • Verify frontmatter position sorting - I documented that you can add a position field to frontmatter to control page order. I found evidence of this in git commits but didn't verify the implementation. Please test:

    • Create markdown files with position: 1, position: 2, etc. in frontmatter
    • Verify they appear in that order in the navigation
    • Verify files without position appear alphabetically after positioned files
  • Check configuration options completeness - Verify all the options I documented (title, slug, icon, collapsed, hidden, skip-slug, availability) actually work with folder configuration and aren't just generic options that don't apply.

  • Verify the Slack example - The example from Slack's documentation (lines 238-257) is based on the Slack conversation quote. Please verify this example is accurate and complete.

  • Preview the documentation - Build the docs locally or check the PR preview to ensure:

    • The page renders correctly
    • Code blocks are properly formatted
    • The page appears in the correct location in the navigation
    • Links work (if any)

Notes

Add comprehensive documentation for the new folder configuration feature
that allows automatic navigation generation from a folder of markdown files.

The documentation covers:
- Basic usage and how it works
- Filename to title/slug conversion rules
- Nested folder support
- All configuration options (title, slug, icon, collapsed, hidden, etc.)
- Combining folder and manual navigation
- Controlling page order with frontmatter
- Use cases and real-world examples

Includes example from Slack's documentation showing the feature in action.

Co-Authored-By: Deep Singhvi <[email protected]>
@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring


The folder configuration allows you to automatically generate navigation from a folder of markdown files. Instead of manually listing each page in your `docs.yml` file, you can point to a folder and Fern will automatically discover and add all markdown files to your navigation.

This feature is useful when you have many pages in a section and want to avoid manually maintaining the navigation structure, or when you want to quickly add multiple pages without updating the configuration file.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 [vale] reported by reviewdog 🐶
[FernStyles.Adverbs] Remove 'quickly' if it's not important to the meaning of the statement.


**Large documentation sets**: When you have dozens or hundreds of pages, manually maintaining the navigation structure in `docs.yml` becomes tedious. Folder-based navigation lets you organize pages in the filesystem and have the navigation generated automatically.

**Frequently updated content**: If you regularly add new pages to a section, folder-based navigation eliminates the need to update `docs.yml` every time you add a page.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 [vale] reported by reviewdog 🐶
[FernStyles.Adverbs] Remove 'regularly' if it's not important to the meaning of the statement.


**Team collaboration**: When multiple team members are adding documentation, folder-based navigation reduces merge conflicts in the `docs.yml` file since new pages don't require configuration changes.

## Example from Slack
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 [vale] reported by reviewdog 🐶
[FernStyles.Headings] 'Example from Slack' should use sentence-style capitalization.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 4, 2025

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.

1 participant