Update i18n.md

pull/4060/head
Polaris 1 year ago committed by GitHub
parent 87577d74e2
commit 49602b8be2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -51,7 +51,7 @@ interface LocaleSpecificConfig<ThemeConfig = any> {
Refer [`DefaultTheme.Config`](https://github.com/vuejs/vitepress/blob/main/types/default-theme.d.ts) interface for details on customizing the placeholder texts of the default theme. Don't override `themeConfig.algolia` or `themeConfig.carbonAds` at locale-level. Refer [Algolia docs](../reference/default-theme-search#i18n) for using multilingual search.
**Pro tip:** Config file can be stored at `docs/.vitepress/config/index.ts` too. It might help you organize stuff by creating a configuration file per locale and then merge and export them from `index.ts`.
**Pro tip:** Config file can be stored at `docs/.vitepress/config/index.ts` too. It might help you organize stuff by creating a configuration file per locale and then to merge and export them from `index.ts`.
## Separate directory for each locale
@ -75,7 +75,7 @@ However, VitePress won't redirect `/` to `/en/` by default. You'll need to confi
/* /en/:splat 302
```
**Pro tip:** If using the above approach, you can use `nf_lang` cookie to persist user's language choice:
**Pro tip:** If using the above approach, you can use `nf_lang` cookie to make the user's language choice persistent:
```ts
// docs/.vitepress/theme/index.ts

Loading…
Cancel
Save