mirror of
https://github.com/thedjinn/js303.git
synced 2025-08-17 15:58:13 +02:00
28 lines
933 B
JavaScript
28 lines
933 B
JavaScript
"use strict";
|
|
function __es6_transpiler_warn__(warning) {
|
|
if (typeof console === 'undefined') {
|
|
} else if (typeof console.warn === "function") {
|
|
console.warn(warning);
|
|
} else if (typeof console.log === "function") {
|
|
console.log(warning);
|
|
}
|
|
}
|
|
function __es6_transpiler_build_module_object__(name, imported) {
|
|
var moduleInstanceObject = Object.create ? Object.create(null) : {};
|
|
if (typeof imported === "function") {
|
|
__es6_transpiler_warn__("imported module '"+name+"' exported a function - this may not work as expected");
|
|
}
|
|
for (var key in imported) {
|
|
if (Object.prototype.hasOwnProperty.call(imported, key)) {
|
|
moduleInstanceObject[key] = imported[key];
|
|
}
|
|
}
|
|
if (Object.freeze) {
|
|
Object.freeze(moduleInstanceObject);
|
|
}
|
|
return moduleInstanceObject;
|
|
}
|
|
var hooks = __es6_transpiler_build_module_object__("hooks", require("htmlbars-runtime/hooks"));
|
|
|
|
var hooks;
|
|
exports.hooks = hooks; |