Commit d884d442 authored by Eirik Alvær's avatar Eirik Alvær
Browse files

Loads languages in a way that won't produce 404 errors.

parent 665aeee0
...@@ -36,8 +36,8 @@ ...@@ -36,8 +36,8 @@
"http://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/js/bootstrap.min.js", "http://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/js/bootstrap.min.js",
"libraries/i18next-1.6.3.js", "libraries/i18next-1.6.3.js",
// Our own scripts // Our own scripts
"js/init.js",
"js/common.js", "js/common.js",
"js/init.js",
"js/model.js", "js/model.js",
"js/templates-loader.js", "js/templates-loader.js",
"js/metadata-maker.js", "js/metadata-maker.js",
......
var resourceStore = {}
resourceStore.en = {};
resourceStore.en.translation = getSyncJSON("locales/translation.en.json");
i18n.init({ i18n.init({
fallbackLng: 'en', fallbackLng: 'en',
debug: true, debug: true,
getAsync: false, getAsync: false,
resGetPath: 'locales/__ns__.__lng__.json' resStore: resourceStore
}); });
Handlebars.registerHelper('t', function(i18n_key) { Handlebars.registerHelper('t', function(i18n_key) {
......
...@@ -2,7 +2,8 @@ ...@@ -2,7 +2,8 @@
"headings" : { "headings" : {
"studies" : "Studies", "studies" : "Studies",
"variables" : "Variables", "variables" : "Variables",
"study_description" : "Study Description", "study_title" : "Study Title",
"abstract" : "Abstract",
"variable_description" : "Variable Description", "variable_description" : "Variable Description",
"label" : "Label" "label" : "Label"
}, },
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment