Merge pull request #3134 from overleaf/as-react-i18n

Load translations in the frontend using react-i18next

GitOrigin-RevId: 4e6ab1befcd783db2b3255bb4d04dc18e710a3dc
This commit is contained in:
Alasdair Smith
2020-09-05 02:05:04 +00:00
committed by Copybot
parent 473e9d32f2
commit 617fe024bc
12 changed files with 208 additions and 14 deletions
+5
View File
@@ -75,6 +75,11 @@ html(
};
window.ab = {};
window.user_id = '#{getLoggedInUserId()}';
//- Internationalisation settings
window.i18n = {
currentLangCode: '#{currentLngCode}'
}
//- Expose some settings globally to the frontend
window.ExposedSettings = JSON.parse('!{StringHelper.stringifyJsonForScript(ExposedSettings)}');
- if (typeof(settings.algolia) != "undefined")