Skip to content

Commit

Permalink
fix i18n setup to avoid setInterval call, allowing node to exit cleanly
Browse files Browse the repository at this point in the history
  • Loading branch information
goastler committed Jan 31, 2024
1 parent 652d6f1 commit c9f1ccc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/common/src/i18n.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ if (isClientSide()) {
.use(initReactI18next)
.init({ ...commonOptions, ...reactOptions })
} else {
i18n.use(Backend)
i18n.use(new Backend(undefined, { reloadInterval: false })) // THIS IS THE LINE THAT CAUSES THE ERROR WHERE VITE NEVER EXITS THE BUNDLING PROCESS! It is due to a setInterval call in this class. Set reloadInterval to false to avoid the interval setup.
.use(MiddlewareLanguageDetector)
.init({ ...commonOptions, ...nodeOptions })
}
Expand Down

0 comments on commit c9f1ccc

Please sign in to comment.