NavTitle eject-only
This component is an eject-only component, specifically designed for wrap/eject, and it's not recommended to be used directly in MDX files.
This component is part of the navigation bar. NavTitle renders the site logo and title in the top-left corner of the navigation bar.
Usage
The component automatically reads configuration from your rspress.config.ts:
Custom NavTitle
You can customize NavTitle through the Layout component's navTitle prop:
Or use the beforeNavTitle and afterNavTitle props to insert custom content:
Configuration
logo
- Type:
string | { light: string; dark: string }
The site logo. Can be a single image path or separate images for light/dark modes.
logoText
- Type:
string
Text to display next to the logo.
title
- Type:
string
The site title. Displayed when neither logo nor logoText is configured.
i18n Support
For multi-language sites, configure title in each locale:
The NavTitle component will automatically display the correct title based on the current locale.