1 | "use strict";
|
2 |
|
3 | function _commander() {
|
4 | const data = require("commander");
|
5 |
|
6 | _commander = function () {
|
7 | return data;
|
8 | };
|
9 |
|
10 | return data;
|
11 | }
|
12 |
|
13 | function _core() {
|
14 | const data = require("@babel/core");
|
15 |
|
16 | _core = function () {
|
17 | return data;
|
18 | };
|
19 |
|
20 | return data;
|
21 | }
|
22 |
|
23 | function collect(value, previousValue) {
|
24 | if (typeof value !== "string") return previousValue;
|
25 | const values = value.split(",");
|
26 |
|
27 | if (previousValue) {
|
28 | previousValue.push(...values);
|
29 | return previousValue;
|
30 | }
|
31 |
|
32 | return values;
|
33 | }
|
34 |
|
35 | _commander().option("-l, --whitelist [whitelist]", "Whitelist of helpers to ONLY include", collect);
|
36 |
|
37 | _commander().option("-t, --output-type [type]", "Type of output (global|umd|var)", "global");
|
38 |
|
39 | _commander().usage("[options]");
|
40 |
|
41 | _commander().parse(process.argv);
|
42 |
|
43 | console.log((0, _core().buildExternalHelpers)(_commander().whitelist, _commander().outputType)); |
\ | No newline at end of file |