Skip to content

Virtual whiteboard for sketching hand-drawn like diagrams

fix: delay loading until language imported (#5344)

Aakansha Doshi39d17c4a3ca3
diff --git a/src/components/InitializeApp.tsx b/src/components/InitializeApp.tsx
index f6ff278d38..c1941512a0 100644
--- a/src/components/InitializeApp.tsx
+++ b/src/components/InitializeApp.tsx
@@ -14,11 +14,11 @@ export const InitializeApp = (props: Props) => {
useEffect(() => {
const updateLang = async () => {
await setLanguage(currentLang);
+ setLoading(false);
};
const currentLang =
languages.find((lang) => lang.code === props.langCode) || defaultLang;
updateLang();
- setLoading(false);
}, [props.langCode]);
return loading ? <LoadingMessage /> : props.children;