Files
2026-07-07 17:53:33 +08:00

34 KiB

[email protected]

Default to Base UI

Internal packages & templates now use Base UI rather than Radix UI.

[email protected]

Require collection query param at regex matching

Instead of passing through all JSON/YAML files, the meta loader now requires collection query param to be triggered.

next-docs-mdx

15.0.12

Patch Changes

15.0.11

Patch Changes

  • 2d65ceb: Support hot reload in source.config.ts with Vite plugin

15.0.10

Patch Changes

15.0.9

Patch Changes

  • cd04425: Support _fumadocs_skipViteConfig internal flag

15.0.8

Patch Changes

15.0.7

Patch Changes

15.0.6

Patch Changes

15.0.5

Patch Changes

  • 1fb6a61: Support custom base directory for content sources

15.0.4

Patch Changes

  • 819b6ec: Support Rolldown integration

15.0.3

Patch Changes

15.0.2

Patch Changes

  • 298ac97: fix compatibility issues with Vite RSC
  • b212481: remove vitefu from inline deps

15.0.1

Patch Changes

15.0.0

Major Changes

  • 3de9dfe: Require ESM for next.config

    Modern Node.js now supports next.config.mts format, compatibility layer is no longer needed.

  • 3de9dfe: Raise minimum fumadocs-core version to 16.7.0

Patch Changes

14.3.2

Patch Changes

14.3.1

Patch Changes

  • a744f9f: Support frontmatter parsing at core-level

14.3.0

Minor Changes

  • fa9f678: Make Next.js config ESM only

    Newer Next.js supported .mts extension for Next.js config files, see Next.js docs for more info.

14.2.14

Patch Changes

14.2.13

Patch Changes

14.2.12

Patch Changes

14.2.11

Patch Changes

  • 3144149: Fix dynamic index generation so generated dynamic.ts imports node:path and passes lazy entries to create.doc() / create.docs() as arrays.
  • Updated dependencies [f45d703]
  • Updated dependencies [45aa454]

14.2.10

Patch Changes

14.2.9

Patch Changes

14.2.8

Patch Changes

14.2.7

Patch Changes

14.2.6

Patch Changes

  • 339dedf: Add heading IDs into processed markdown by default

14.2.5

Patch Changes

14.2.4

Patch Changes

14.2.3

Patch Changes

14.2.2

Patch Changes

14.2.1

Patch Changes

14.2.0

Minor Changes

  • 8ce2c70: Add VS Code-style #region / #endregion support to for code files

14.1.1

Patch Changes

  • adaf9ae: hotfix Windows path escape

14.1.0

Minor Changes

  • fc0e3db: Support Workspaces API [Experimental]

Patch Changes

14.0.4

Patch Changes

14.0.3

Patch Changes

14.0.2

Patch Changes

14.0.1

Patch Changes

14.0.0

Major Changes

  • 7b450d6: Change postInstall() signature to postInstall({ configPath, outDir, ... })

    This allows more options for postInstall command.

  • a312d3a: Replace getDefaultMDXOptions() with applyMdxPreset()

    This allows Fumadocs MDX to support more presets in the future, and adjust presets for dynamic mode.

    // source.config.ts
    import { defineCollections, applyMdxPreset } from "fumadocs-mdx/config";
    import { myPlugin } from "./remark-plugin";
    
    export const blog = defineCollections({
      type: "doc",
      mdxOptions: applyMdxPreset({
        remarkPlugins: [myPlugin],
        // You can also pass a function to control the order of remark plugins.
        remarkPlugins: (v) => [myPlugin, ...v],
      }),
    });
    
  • bc93578: Replace lastModifiedTime option with lastModified plugin.

    If you've lastModifiedTime option enabled before, migrate to the plugin instead.

    // source.config.ts
    import { defineConfig } from "fumadocs-mdx/config";
    import lastModified from "fumadocs-mdx/plugins/last-modified";
    
    export default defineConfig({
      plugins: [lastModified()],
    });
    
  • 2f7e4d8: Drop support for multiple dir in same collection

    Consider using files instead for filtering files.

    // source.config.ts
    import { defineDocs } from "fumadocs-mdx/config";
    
    export const docs = defineDocs({
      dir: "content/guides",
      docs: {
        files: ["./i-love-fumadocs/**/*.{md,mdx}"],
      },
    });
    
  • a312d3a: No longer generate extractedReferences by default

    You can enable it from postprocess option.

    // source.config.ts
    import { defineDocs } from "fumadocs-mdx/config";
    
    export const docs = defineDocs({
      docs: {
        postprocess: {
          extractLinkReferences: true,
        },
      },
    });
    
  • b963021: [Vite] rename generateIndexFile option to index

Patch Changes

13.0.8

Patch Changes

13.0.7

Patch Changes

13.0.6

Patch Changes

13.0.5

Patch Changes

  • ad38466: add support next.config.mts for mdx

13.0.4

Patch Changes

  • 27fc4ed: [Internal] improve mutability of LoadedConfig for plugins
  • f5bc4aa: Fix Bun missing query strings
  • 61b90c8: Always transform meta files in collection, this includes runtime loaders like Node.js and Bun.
  • d1e43f4: Support re-generating index file when using runtime: bun | node
  • Updated dependencies [f97cd1e]
  • Updated dependencies [f7e15e2]

13.0.3

Patch Changes

13.0.2

Patch Changes

  • ee4ad3d: Always format file paths into POSIX for Vite

13.0.1

Patch Changes

  • 56332df: Support plugins in Webpack loader environment: now plugins can apply changes on MDX options too.
  • 91add4f: Plugin json-schema: support inserting $schema to JSON files
  • cffd4c2: Lazy update index files on Next.js

13.0.0

Major Changes

  • 8d0c164: Move createMDXSource and resolveFiles from fumadocs-mdx to fumadocs-mdx/runtime/next

  • 3caa5cd: Vite: move source.generated.ts to .source/index.ts

    Why:

    • with Fumadocs MDX Plugins, we want to unify the output directory across Vite & Next.js.
    • source.generated.ts looks ugly compared by .source.

    Migrate:

    • run dev server/typegen to generate a .source folder.
    • import it over the original source.generated.ts.
    • note that both docs and create-fumadocs-app are updated to .source folder.

Minor Changes

  • 29ce826: Support JSON Schema plugin (fumadocs-mdx/plugins/json-schema)

  • 3caa5cd: Support Plugins API

    Fumadocs MDX is mostly a bundler plugin meant to be used with tools like Vite and Turbopack.

    With Fumadocs MDX Plugins, you can extend Fumadocs MDX without worrying the underlying bundler. It is designed for:

    • Generate files from config (e.g. types, index files, JSON schemas)
    • Modify received config

Patch Changes

  • 81fa875: Fix includeProcessedMarkdown cannot stringify MDX nodes
  • 575cfb8: Include unravel plugin into remark-include parsing step, this ensures the parsed results are consistent with normal MDX.js processor output.
  • 1f1c787: Add useContent API to client loader for avoiding Lint errors
  • 9051574: Support postprocess.includeMDAST option
  • a5df956: Support runtime: bun and runtime: node in Vite index file generation
  • 5210f18: Support Fumadocs 16 in peerDependencies.
  • Updated dependencies [230c6bf]
  • Updated dependencies [851897c]
  • Updated dependencies [4049ccc]
  • Updated dependencies [429c41a]
  • Updated dependencies [5210f18]
  • Updated dependencies [cbc93e9]
  • Updated dependencies [42f09c3]
  • Updated dependencies [55afd8a]
  • Updated dependencies [5210f18]

12.0.3

Patch Changes

12.0.2

Patch Changes

12.0.1

Patch Changes

12.0.0

Major Changes

  • f11f89d: [Next.js] Rename APIS

    On page data:

    • _file -> info.
    • _file.absolutePath -> info.fullPath.
  • effe43d: Drop support for Zod 3 schemas

    Zod 3 schemas are still allowed, but you cannot no longer extend on the Zod 4 schemas provided by Fumadocs.

  • 2862a10: [Next.js] Removed content on page data in favour of getText().

Minor Changes

  • 22e0fec: Support getText() & Postprocess API
  • 2862a10: Unify doc collection entry for both Vite and Next.js integrations

11.10.1

Patch Changes

11.10.0

Minor Changes

  • ea13374: Support runtime loaders: Node.js, Bun

Patch Changes

11.9.1

Patch Changes

  • 64d0169: hotfix node.js imports at global scope

11.9.0

Minor Changes

  • d193152: Support absolutePath on Vite

Patch Changes

11.8.3

Patch Changes

11.8.2

Patch Changes

  • 9a3c23b: support auto-generated title based on h1 heading
  • 9cb829c: Support referencing heading in <include> without sections

11.8.1

Patch Changes

11.8.0

Minor Changes

  • cfe2a5c: Support Async Mode for Vite

Patch Changes

11.7.5

Patch Changes

  • c17fa03: Support creating a separate processor when <include /> points to different Markdown format
  • f43f714: Automatic fallback to Zod v3 when app has explicit v3 dependency
  • Updated dependencies [569bc26]
  • Updated dependencies [817c237]

11.7.4

Patch Changes

  • a0148f9: Remark Include: Support copying only a section

11.7.3

Patch Changes

  • 4f8f1d6: Add vite/client types in generated file
  • 57224f4: Support last modified time for Vite

11.7.2

Patch Changes

  • e75ec55: Support last modified time for Vite

11.7.1

Patch Changes

11.7.0

Minor Changes

  • f8a58c6: Support preset: minimal to disable Fumadocs specific defaults
  • e5cfa27: Stabilize Vite plugin support

Patch Changes

11.6.11

Patch Changes

11.6.10

Patch Changes

11.6.9

Patch Changes

11.6.8

Patch Changes

11.6.7

Patch Changes

11.6.6

Patch Changes

11.6.5

Patch Changes

11.6.4

Patch Changes

11.6.3

Patch Changes

11.6.2

Patch Changes

11.6.1

Patch Changes

11.6.0

Minor Changes

  • 7fcf612: Require Next.js 15.3.0 or above

Patch Changes

11.5.8

Patch Changes

11.5.7

Patch Changes

11.5.6

Patch Changes

11.5.5

Patch Changes

11.5.4

Patch Changes

11.5.3

Patch Changes

11.5.2

Patch Changes

11.5.1

Patch Changes

11.5.0

Minor Changes

  • 233a2d1: Support Standard Schema for collection schema
  • 432c7bd: Support defineDocs without re-exporting docs and meta collections

Patch Changes

11.4.1

Patch Changes

11.4.0

Minor Changes

  • 421166a: Improve performance, remove unused imports

Patch Changes

11.3.2

Patch Changes

11.3.1

Patch Changes

11.3.0

Minor Changes

  • a4eb326: Deprecate generateManifest option: use a route handler to export build time information

Patch Changes

  • 7cc9f1f: Support CommonJs usage temporarily

11.2.3

Patch Changes

11.2.2

Patch Changes

11.2.1

Patch Changes

11.2.0

Minor Changes

  • bd0a140: Support reusing content with include tag

Patch Changes

11.1.2

Patch Changes

11.1.1

Patch Changes

11.1.0

Minor Changes

  • 28a9c3c: Migrate loaders to ESM only

11.0.0

Major Changes

Patch Changes

10.1.0

Minor Changes

  • 5cef1f1: Move dir option from defineDocs
  • e1ee822: Support hast nodes in toc variable
  • df9e0e1: Support async output mode

Patch Changes

10.0.2

Patch Changes

10.0.1

Patch Changes

10.0.0

Major Changes

  • ed83d01: Support declarative collections

    why: This allows Fumadocs MDX to be more flexible.

    migrate:

    You don't need exports anymore, properties are merged into one object by default.

    - page.data.exports.toc
    + page.data.toc
    
    - page.data.exports.default
    + page.data.body
    

    A source.config.ts is now required.

    import { defineDocs, defineConfig } from "fumadocs-mdx/config";
    
    export const { docs, meta } = defineDocs();
    
    export default defineConfig();
    

    The mdx-components.tsx file is no longer used, pass MDX components to body instead.

    Search indexes API is now replaced by Manifest API.

    Please refer to the docs for further details.

Patch Changes

9.0.4

Patch Changes

9.0.3

Patch Changes

9.0.2

Patch Changes

9.0.1

Patch Changes

9.0.0

Major Changes

Patch Changes

8.2.34

Patch Changes

8.2.33

Patch Changes

8.2.32

Patch Changes

8.2.31

Patch Changes

8.2.30

Patch Changes

8.2.29

Patch Changes

8.2.28

Patch Changes

8.2.27

Patch Changes

8.2.26

Patch Changes

8.2.25

Patch Changes

8.2.24

Patch Changes

8.2.23

Patch Changes

8.2.22

Patch Changes

8.2.21

Patch Changes

8.2.20

Patch Changes

8.2.19

Patch Changes

8.2.18

Patch Changes

8.2.17

Patch Changes

8.2.16

Patch Changes

8.2.15

Patch Changes

8.2.14

Patch Changes

8.2.13

Patch Changes

8.2.12

Patch Changes

8.2.11

Patch Changes

8.2.10

Patch Changes

8.2.9

Patch Changes

8.2.8

Patch Changes

8.2.7

Patch Changes

8.2.6

Patch Changes

8.2.5

Patch Changes

8.2.4

Patch Changes

8.2.3

Patch Changes

8.2.2

Patch Changes

8.2.1

Patch Changes

8.2.0

Minor Changes

  • 01155f5: Support generate search indexes in build time

Patch Changes

8.1.1

Patch Changes

8.1.0

Minor Changes

  • 1c388ca5: Support defaultOpen for folder nodes

Patch Changes

8.0.5

Patch Changes

8.0.4

Patch Changes

8.0.3

Patch Changes

8.0.2

Patch Changes

8.0.1

Patch Changes

8.0.0

Major Changes

  • 1a346a1: Enable remark-image plugin by default

    You can add image embeds easily. They will be converted to static image imports.

    ![banner](/image.png)
    

    Become:

    import img_banner from "../../public/image.png";
    
    <img alt="banner" src={img_banner} />
    
  • 2b11c20: Rename to Fumadocs

    next-docs-zeta -> fumadocs-core

    next-docs-ui -> fumadocs-ui

    next-docs-mdx -> fumadocs-mdx

    @fuma-docs/openapi -> fumadocs-openapi

    create-next-docs-app -> create-fumadocs-app

Patch Changes

7.1.2

Patch Changes

7.1.1

Patch Changes

7.1.0

Patch Changes

7.0.0

Major Changes

  • 9929c5b: Prefer .map.ts instead of _map.ts

    Unless you have especially configured, now it uses .map.ts by default.

    - import map from "@/_map"
    + import map from "@/.map"
    
  • 9929c5b: Migrate to Source API

    fromMap has been removed. Please use createMDXSource instead.

    import { map } from "@/.map";
    import { createMDXSource } from "next-docs-mdx";
    import { loader } from "next-docs-zeta/source";
    
    export const { getPage, getPages, pageTree } = loader({
      baseUrl: "/docs",
      rootDir: "docs",
      source: createMDXSource(map),
    });
    

Minor Changes

  • 8fd769f: Support last modified timestamp for Git

    Enable this in next.config.mjs:

    const withNextDocs = createNextDocs({
      mdxOptions: {
        lastModifiedTime: "git",
      },
    });
    

    Access it via page.data.exports.lastModified.

Patch Changes

6.1.0

Patch Changes

6.0.2

Patch Changes

6.0.1

Patch Changes

6.0.0

Major Changes

  • 69f8abf: Make file paths relative to rootDir when resolving files

    For a more simplified usage, the resolved file paths will be relative to rootDir.

    You can now generate slugs automatically depending on the root directory you have configured.

    const utils = fromMap(map, {
      rootDir: "ui",
      schema: {
        frontmatter: frontmatterSchema,
      },
    });
    

    The configuration above will generate /hello slugs for a file named /content/ui/hello.mdx, while the previous one generates /ui/hello.

  • 9ef047d: Pre-bundle page urls into raw pages.

    This means you don't need getPageUrl anymore for built-in adapters, including next-docs-mdx and Contentlayer. It is now replaced by the url property from the pages array provided by your adapter.

    Due to this change, your old configuration might not continue to work.

    import { fromMap } from 'next-docs-mdx/map'
    
    fromMap({
    -  slugs: ...
    +  getSlugs: ...
    })
    

    For Contentlayer, the getUrl option is now moved to createConfig.

  • 1c187b9: Support intelligent schema types

    The validate options is now renamed to schema.

    import { defaultSchemas, fromMap } from "next-docs-mdx/map";
    
    const utils = fromMap(map, {
      rootDir: "docs/ui",
      baseUrl: "/docs/ui",
      schema: {
        frontmatter: defaultSchemas.frontmatter.extend({
          preview: z.string().optional(),
        }),
      },
    });
    

    The frontmatter field on pages should be automatically inferred to your Zod schema type.

  • 52b24a6: Remove /docs from default root content path

    Previously, the default root content path is ./content/docs. All your documents must be placed under the root directory.

    Since this update, it is now ./content by default. To keep the old behaviours, you may manually specify rootContentPath.

    const withNextDocs = createNextDocs({
      rootContentPath: "./content/docs",
    });
    

    Notice that due to this change, your baseUrl property will be / by default

    const withNextDocs = createNextDocs({
    +  baseUrl: "/docs"
    })
    
  • 2ff7581: Rename configuration options

    The options of createNextDocs is now renamed to be more flexible and straightforward.

    Old New
    dataExports mdxOptions.valueToExport
    pluginOptions mdxOptions.rehypeNextDocsOptions

    rehypePlugins and remarkPlugins can also be a function that accepts and returns plugins.

Minor Changes

  • 55a2321: Use @mdx-js/mdx to process MDX/markdown files.

    You no longer need @next/loader and @mdx-js/loader to be installed on your project, next-docs-mdx will process files with @mdx-js/mdx directly.

    This change will not break most of the projects

Patch Changes

5.0.0

Minor Changes

  • de44efe: Migrate to Shikiji
  • de44efe: Support code highlighting options

Patch Changes

4.0.9

Patch Changes

4.0.8

Patch Changes

4.0.7

Patch Changes

4.0.6

Patch Changes

4.0.5

Patch Changes

4.0.4

Patch Changes

4.0.3

Patch Changes

4.0.2

Patch Changes

4.0.1

Patch Changes

4.0.0

Patch Changes

4.0.0

Patch Changes

3.0.0

Patch Changes