Getting Started
Prerequisites
- Node.js 20 or later
- npm, pnpm, or yarn
Install
npm installDevelop
npm run devOpen http://localhost:3000 . Edits to files in content/ reload automatically.
Build
npm run build
npm run startAdd a Page
- Create a new
.mdxfile undercontent/(e.g.content/docs/api.mdx). - Add it to the matching
_meta.jsto control the sidebar order and title.
content/docs/_meta.js
export default {
index: 'Introduction',
'getting-started': 'Getting Started',
api: 'API Reference',
deployment: 'Deployment'
}Components
Nextra ships with several built-in MDX components:
This is an info callout. Use type="warning", error, or default for other styles.
Last updated on