Proof of work. Load JSON file directly

instead of having to create a .js file with translations.
This commit is contained in:
JC Brand 2015-01-16 21:04:38 +01:00
parent ba09fa1fbb
commit d22ab21bbf
2 changed files with 5 additions and 3 deletions

View File

@ -6,8 +6,7 @@
*/ */
(function (root, factory) { (function (root, factory) {
define("locales", [ define("locales", ['jquery', 'jed',
'jed',
'af', 'af',
'de', 'de',
'en', 'en',
@ -20,10 +19,11 @@
'ja', 'ja',
'nb', 'nb',
'nl', 'nl',
'text!pl',
'pt_BR', 'pt_BR',
'ru', 'ru',
'zh' 'zh'
], function (jed, af, de, en, es, fr, he, hu, id, it, ja, nb, nl, pt_BR, ru, zh) { ], function ($, Jed, af, de, en, es, fr, he, hu, id, it, ja, nb, nl, pl, pt_BR, ru, zh) {
root.locales = { root.locales = {
'af': af, 'af': af,
'de': de, 'de': de,
@ -37,6 +37,7 @@
'ja': ja, 'ja': ja,
'nb': nb, 'nb': nb,
'nl': nl, 'nl': nl,
'pl': new Jed($.parseJSON(pl)),
'pt-br': pt_BR, 'pt-br': pt_BR,
'ru': ru, 'ru': ru,
'zh':zh 'zh':zh

View File

@ -70,6 +70,7 @@ require.config({
"ja": "locale/ja/LC_MESSAGES/ja", "ja": "locale/ja/LC_MESSAGES/ja",
"nb": "locale/nb/LC_MESSAGES/nb", "nb": "locale/nb/LC_MESSAGES/nb",
"nl": "locale/nl/LC_MESSAGES/nl", "nl": "locale/nl/LC_MESSAGES/nl",
"pl": "locale/pl/LC_MESSAGES/converse.json",
"pt_BR": "locale/pt_BR/LC_MESSAGES/pt_BR", "pt_BR": "locale/pt_BR/LC_MESSAGES/pt_BR",
"ru": "locale/ru/LC_MESSAGES/ru", "ru": "locale/ru/LC_MESSAGES/ru",
"zh": "locale/zh/LC_MESSAGES/zh", "zh": "locale/zh/LC_MESSAGES/zh",