nextra
tip
- 支持 SSG, SSR, ISR
- shuding/nextra
- Next.js Static Site Generator
- remark
- 高亮 shikijs
- markdown 由 nextra/loader 处理
- https://nextra.site/showcase
- templates
- 参考
- /
- theme.config.{jsx,tsx}
- pages/
- index.{md,mdx}
- _meta.json
- title 映射
- 顺序
markdown
GFM
## 标题 [#title]
- 高亮语言
- VSCode TextMate Grammar
- https://github.com/shikijs/shiki/blob/main/docs/languages.md
docs
theme.config.jsx
// https://nextra.site/docs/docs-theme/theme-configuration
export default {
logo: <span>My Nextra Documentation</span>,
project: {
link: 'https://github.com/wenerme/wener',
},
};
_meta.json
{
"index": {
"title": "Home",
"type": "page",
"theme": {
"layout": "raw",
"typesetting": "article",
"breadcrumb": false,
"footer": true,
"sidebar": false,
"toc": true,
"pagination": false
}
},
"contact": {
"display": "hidden"
},
"about": "About Us",
"github_link": {
"title": "Wener Github",
"href": "https://github.com/wenerme",
"newWindow": true
},
"company": {
"title": "Company",
"type": "menu",
"items": {
"about": {
"title": "About",
"href": "/about"
},
"contact": {
"title": "Contact Us",
"href": "mailto:[email protected]"
}
}
},
"*": {
"type": "page"
},
"---": {
"type": "separator"
}
}
- typesetting - default, article
- layout - raw, full