Skip to content

Commit

Permalink
🐛 fix: Fix ssr
Browse files Browse the repository at this point in the history
  • Loading branch information
canisminor1990 committed Jul 17, 2023
1 parent a834e76 commit 9a13ec0
Show file tree
Hide file tree
Showing 15 changed files with 39 additions and 444 deletions.
2 changes: 1 addition & 1 deletion .i18nrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ module.exports = defineConfig({
entry: 'public/locales/zh_CN',
entryLocale: 'zh_CN',
output: 'public/locales',
outputLocales: ['zh_HK', 'en_US', 'ja_JP', 'ko_KR'],
outputLocales: ['en_US'],
splitToken: 2500,
temperature: 0,
modelName: 'gpt-3.5-turbo',
Expand Down
6 changes: 1 addition & 5 deletions next-i18next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const i18n = require('./.i18nrc');

/** @type {import('next-i18next').UserConfig} */
module.exports = {
debug: process.env.NODE_ENV === 'development',
//debug: process.env.NODE_ENV === 'development',
fallbackLng: {
default: ['zh_CN'],
zh_TW: ['zh_CN'],
Expand All @@ -11,9 +11,5 @@ module.exports = {
defaultLocale: i18n.entryLocale,
locales: [i18n.entryLocale, ...i18n.outputLocales],
},
localePath:
typeof window === 'undefined' ? require('node:path').resolve('./', i18n.output) : '/locales',
react: { useSuspense: false },
reloadOnPrerender: process.env.NODE_ENV === 'development',
strictMode: true,
};
40 changes: 0 additions & 40 deletions public/locales/ja_JP/common.json

This file was deleted.

97 changes: 0 additions & 97 deletions public/locales/ja_JP/setting.json

This file was deleted.

40 changes: 0 additions & 40 deletions public/locales/ko_KR/common.json

This file was deleted.

97 changes: 0 additions & 97 deletions public/locales/ko_KR/setting.json

This file was deleted.

40 changes: 0 additions & 40 deletions public/locales/zh_HK/common.json

This file was deleted.

Loading

0 comments on commit 9a13ec0

Please sign in to comment.