Introduction
Getting started with core library
What is this?
Fumadocs Core offers server-side functions and headless components to build docs on any React.js frameworks like Next.js.
- Search (built-in: Orama, Algolia Search)
- Breadcrumb, Sidebar, TOC Components
- Remark/Rehype Plugins
- Additional utilities
Tip
It can be used without Fumadocs UI, in other words, it's headless.
For beginners and normal usages, use Fumadocs UI.
Installation
No other dependencies required.
npm install fumadocs-core
pnpm add fumadocs-core
yarn add fumadocs-core
bun add fumadocs-core
For some components, a framework provider is needed:
import type { ReactNode } from 'react';
import { NextProvider } from 'fumadocs-core/framework/next';
export function RootLayout({ children }: { children: ReactNode }) {
// or if you're using Fumadocs UI, use `<RootProvider />`
return <NextProvider>{children}</NextProvider>;
}
import type { ReactNode } from 'react';
import { ReactRouterProvider } from 'fumadocs-core/framework/react-router';
export function Root({ children }: { children: ReactNode }) {
return <ReactRouterProvider>{children}</ReactRouterProvider>;
}
import type { ReactNode } from 'react';
import { TanstackProvider } from 'fumadocs-core/framework/tanstack';
export function Root({ children }: { children: ReactNode }) {
return <TanstackProvider>{children}</TanstackProvider>;
}
It offers simple document searching as well as components for building a good docs.
How is this guide?