1 | (function (factory) {
|
2 | if (typeof module === "object" && typeof module.exports === "object") {
|
3 | var v = factory(require, exports);
|
4 | if (v !== undefined) module.exports = v;
|
5 | }
|
6 | else if (typeof define === "function" && define.amd) {
|
7 | define(["require", "exports"], factory);
|
8 | }
|
9 | })(function (require, exports) {
|
10 | "use strict";
|
11 | Object.defineProperty(exports, "__esModule", { value: true });
|
12 | const node_libs = ["child_process", "fs", "node-fetch", "os", "path", "semver", "safe-buffer", "tmp", "xmldom"];
|
13 | exports.isHpcc = (id) => id.indexOf("@hpcc-js") === 0;
|
14 | exports.isShim = (id) => exports.isHpcc(id) && id.indexOf("-shim") > 0;
|
15 | function external(id) {
|
16 | return (exports.isHpcc(id) && !exports.isShim(id)) || node_libs.indexOf(id) >= 0;
|
17 | }
|
18 | exports.external = external;
|
19 | function globals(id) {
|
20 | if (id.indexOf("@hpcc-js") === 0) {
|
21 | return id;
|
22 | }
|
23 | return undefined;
|
24 | }
|
25 | exports.globals = globals;
|
26 | });
|