Skip to content
This repository was archived by the owner on Jan 2, 2025. It is now read-only.

Commit 4e6e4cb

Browse files
fix localisation on cloud
1 parent 6e02064 commit 4e6e4cb

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

client/src/CloudApp.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ import packageJson from '../package.json';
44
import { getConfig } from './services/api';
55
import App from './App';
66
import { LocaleContext } from './context/localeContext';
7+
import i18n from './i18n';
8+
import { LANGUAGE_KEY, savePlainToStorage } from './services/storage';
79

810
const CloudApp = () => {
911
const [envConfig, setEnvConfig] = useState({});
@@ -41,7 +43,8 @@ const CloudApp = () => {
4143
);
4244

4345
useEffect(() => {
44-
// dynamicActivate(locale);
46+
i18n.changeLanguage(locale);
47+
savePlainToStorage(LANGUAGE_KEY, locale);
4548
}, [locale]);
4649

4750
const localeContextValue = useMemo(

0 commit comments

Comments
 (0)