We use tracking cookies to understand how you use the product and help us improve it. For more information on how we store cookies, read our  privacy policy.

Add Doc Page

Learn how to create a new documentation page in Plainform

Learn how to create a new documentation page in your Plainform application.

Goal

By the end of this recipe, you'll have created a new documentation page with proper metadata and navigation.

Prerequisites

  • A working Plainform installation
  • Basic knowledge of Markdown/MDX syntax

Steps

Create MDX File

Create a new .mdx file in the appropriate section:

# Example locations
content/docs/core/new-topic.mdx
content/docs/core/authentication/new-feature.mdx

Use lowercase letters and hyphens for filenames. The filename becomes the URL slug.

Add Frontmatter

Add frontmatter at the top of your file:

---
title: Your Page Title
description: A brief description of the page content
icon: BookOpen
---

# Your Page Title

Your content here...

Browse available icons at lucide.dev.

Add to Navigation

Update the meta.json file in the same directory:

content/docs/core/meta.json
{
  "title": "Core Documentation",
  "pages": [
    "introduction",
    "new-topic"
  ]
}

The page slug in meta.json must match the filename without the .mdx extension.

Preview and Publish

Start your dev server and navigate to your page:

npm run dev

Then commit and push:

git add content/docs/
git commit -m "docs: add new documentation page"
git push origin main

Common Issues

Page Not Appearing

  • Verify the page is listed in meta.json
  • Check that the slug matches the filename exactly
  • Ensure meta.json is valid JSON (no trailing commas)

404 Error

  • Confirm the file is in the correct directory
  • Check that the file has .mdx extension
  • Verify frontmatter is properly formatted with --- markers

Next Steps

How is this guide ?

Last updated on