Files
lobe-chat/.i18nrc.js
T
CanisMinor e97f62f65e 📝 docs: Update docs to fit next RSC (#1939)
* 📝 docs: Update docs to fit next rsc

* 📝 docs: Replace links

* chore: fix i18n config

* 📝 docs: update seo
2024-04-11 00:28:48 +08:00

49 lines
1.2 KiB
JavaScript

const { defineConfig } = require('@lobehub/i18n-cli');
module.exports = defineConfig({
entry: 'locales/zh-CN',
entryLocale: 'zh-CN',
output: 'locales',
outputLocales: [
'ar',
'bg-BG',
'zh-TW',
'en-US',
'ru-RU',
'ja-JP',
'ko-KR',
'fr-FR',
'tr-TR',
'es-ES',
'pt-BR',
'de-DE',
'it-IT',
'nl-NL',
'pl-PL',
'vi-VN',
],
temperature: 0,
modelName: 'gpt-3.5-turbo-0125',
splitToken: 1024,
experimental: {
jsonMode: true,
},
reference:
'You need to maintain the component format of MDX, and the output text does not need to be wrapped in any code block syntax at the outermost level.',
markdown: {
entry: ['./README.zh-CN.md', './contributing/**/*.zh-CN.md', './docs/**/*.zh-CN.mdx'],
entryLocale: 'zh-CN',
outputLocales: ['en-US'],
exclude: ['./contributing/_Sidebar.md', './contributing/_Footer.md', './contributing/Home.md'],
outputExtensions: (locale, { filePath }) => {
if (filePath.includes('.mdx')) {
if (locale === 'en-US') return '.mdx';
return `.${locale}.mdx`;
} else {
if (locale === 'en-US') return '.md';
return `.${locale}.md`;
}
},
},
});