/
main.js
47 lines (40 loc) · 1.03 KB
/
main.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
System.register([], (function (exports) {
'use strict';
return {
execute: (function () {
function _mergeNamespaces(n, m) {
m.forEach(function (e) {
e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
if (k !== 'default' && !(k in n)) {
var d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: function () { return e[k]; }
});
}
});
});
return Object.freeze(n);
}
const d = {
fn: 42,
hello: 'hola'
};
const foo = exports('foo', 100);
var ns = /*#__PURE__*/_mergeNamespaces({
__proto__: null,
default: d,
foo: foo
}, [d]);
const stuff = 12;
console.log(stuff);
console.log(d.fn);
console.log(foo);
console.log(ns);
exports({
fn: d.fn,
stuff: d.stuff
});
})
};
}));