Installation
Prerequisites
Before you begin, make sure you have the following installed:
- Node.js 16.8 or later
- npm or yarn or pnpm
Installation Steps
- Create a new project:
npx create-next-app@latest my-docs
- Install Nextra:
npm install nextra nextra-theme-docs
- Configure your project by updating
next.config.js
:
const withNextra = require('nextra')({
theme: 'nextra-theme-docs',
themeConfig: './theme.config.jsx'
})
module.exports = withNextra()
- Start the development server:
npm run dev
Your documentation site should now be running at http://localhost:3000
!