Share Gaia assets and adapters, keep private profiles and development documents local, and update both public READMEs.
23 lines
518 B
JavaScript
Executable file
23 lines
518 B
JavaScript
Executable file
'use strict';
|
|
define(['l10n!'], function(mozL10n) {
|
|
var tmpl = {
|
|
pluginBuilder: './tmpl_builder',
|
|
|
|
toDom: function(text) {
|
|
var temp = document.createElement('div');
|
|
temp.innerHTML = text;
|
|
var node = temp.children[0];
|
|
mozL10n.translateFragment(node);
|
|
return node;
|
|
},
|
|
|
|
load: function(id, require, onload, config) {
|
|
require(['text!' + id], function(text) {
|
|
var node = tmpl.toDom(text);
|
|
onload(node);
|
|
});
|
|
}
|
|
};
|
|
|
|
return tmpl;
|
|
});
|