@rnx-kit/cli 0.12.7 → 0.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +117 -0
- package/README.md +90 -65
- package/coverage/clover.xml +92 -104
- package/coverage/coverage-final.json +7 -6
- package/coverage/lcov-report/index.html +29 -29
- package/coverage/lcov-report/src/bundle/index.html +29 -29
- package/coverage/lcov-report/src/bundle/kit-config.ts.html +63 -117
- package/coverage/lcov-report/src/bundle/metro.ts.html +40 -163
- package/coverage/lcov-report/src/bundle/overrides.ts.html +28 -58
- package/coverage/lcov-report/src/bundler-plugin-defaults.ts.html +115 -0
- package/coverage/lcov-report/src/copy-assets.ts.html +1 -1
- package/coverage/lcov-report/src/index.html +26 -11
- package/coverage/lcov-report/src/metro-config.ts.html +49 -31
- package/coverage/lcov-report/src/typescript/index.html +1 -1
- package/coverage/lcov-report/src/typescript/project-cache.ts.html +5 -5
- package/coverage/lcov.info +173 -193
- package/lib/bundle/kit-config.d.ts +9 -15
- package/lib/bundle/kit-config.d.ts.map +1 -1
- package/lib/bundle/kit-config.js +34 -43
- package/lib/bundle/kit-config.js.map +1 -1
- package/lib/bundle/metro.d.ts +7 -11
- package/lib/bundle/metro.d.ts.map +1 -1
- package/lib/bundle/metro.js +21 -59
- package/lib/bundle/metro.js.map +1 -1
- package/lib/bundle/overrides.d.ts +11 -9
- package/lib/bundle/overrides.d.ts.map +1 -1
- package/lib/bundle/overrides.js +10 -18
- package/lib/bundle/overrides.js.map +1 -1
- package/lib/bundle/types.d.ts +4 -17
- package/lib/bundle/types.d.ts.map +1 -1
- package/lib/bundle.d.ts +8 -7
- package/lib/bundle.d.ts.map +1 -1
- package/lib/bundle.js +8 -35
- package/lib/bundle.js.map +1 -1
- package/lib/bundler-plugin-defaults.d.ts +3 -0
- package/lib/bundler-plugin-defaults.d.ts.map +1 -0
- package/lib/bundler-plugin-defaults.js +13 -0
- package/lib/bundler-plugin-defaults.js.map +1 -0
- package/lib/clean.js +106 -117
- package/lib/clean.js.map +1 -1
- package/lib/copy-assets.js +194 -210
- package/lib/copy-assets.js.map +1 -1
- package/lib/dep-check.js +12 -7
- package/lib/dep-check.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +2 -1
- package/lib/index.js.map +1 -1
- package/lib/metro-config.d.ts +3 -2
- package/lib/metro-config.d.ts.map +1 -1
- package/lib/metro-config.js +7 -5
- package/lib/metro-config.js.map +1 -1
- package/lib/parsers.d.ts +2 -0
- package/lib/parsers.d.ts.map +1 -1
- package/lib/parsers.js +16 -1
- package/lib/parsers.js.map +1 -1
- package/lib/serve/kit-config.d.ts +6 -5
- package/lib/serve/kit-config.d.ts.map +1 -1
- package/lib/serve/kit-config.js +21 -6
- package/lib/serve/kit-config.js.map +1 -1
- package/lib/start.d.ts +2 -2
- package/lib/start.d.ts.map +1 -1
- package/lib/start.js +146 -158
- package/lib/start.js.map +1 -1
- package/package.json +9 -6
- package/react-native.config.js +65 -59
- package/src/bundle/kit-config.ts +42 -60
- package/src/bundle/metro.ts +15 -56
- package/src/bundle/overrides.ts +24 -34
- package/src/bundle/types.ts +17 -23
- package/src/bundle.ts +18 -36
- package/src/bundler-plugin-defaults.ts +10 -0
- package/src/index.ts +1 -1
- package/src/metro-config.ts +12 -6
- package/src/parsers.ts +19 -0
- package/src/serve/kit-config.ts +23 -11
- package/src/start.ts +23 -29
- package/test/bundle/__mocks__/@rnx-kit/config.js +2 -3
- package/test/bundle/__mocks__/@rnx-kit/console.js +1 -0
- package/test/bundle/__mocks__/@rnx-kit/metro-service.js +1 -0
- package/test/bundle/kit-config.test.ts +102 -100
- package/test/bundle/metro.test.ts +58 -98
- package/test/bundle/overrides.test.ts +29 -25
- package/test/copy-assets/assembleAarBundle.test.ts +1 -0
- package/lib/types.d.ts +0 -5
- package/lib/types.d.ts.map +0 -1
- package/lib/types.js +0 -3
- package/lib/types.js.map +0 -1
- package/src/types.ts +0 -4
package/lib/metro-config.js
CHANGED
|
@@ -14,10 +14,11 @@ const project_cache_1 = require("./typescript/project-cache");
|
|
|
14
14
|
* Source file in node_modules (external packages) are ignored.
|
|
15
15
|
*
|
|
16
16
|
* @param options TypeScript validation options
|
|
17
|
+
* @param print Optional function to use when printing status messages to the Metro console
|
|
17
18
|
* @returns Hook function
|
|
18
19
|
*/
|
|
19
|
-
function createSerializerHook(options) {
|
|
20
|
-
const projectCache = (0, project_cache_1.createProjectCache)(
|
|
20
|
+
function createSerializerHook(options, print) {
|
|
21
|
+
const projectCache = (0, project_cache_1.createProjectCache)(print);
|
|
21
22
|
const patternNodeModules = /[/\\]node_modules[/\\]/;
|
|
22
23
|
const excludeNodeModules = (p) => !patternNodeModules.test(p);
|
|
23
24
|
const hook = (graph, delta) => {
|
|
@@ -83,8 +84,9 @@ const emptySerializerHook = (_graph, _delta) => {
|
|
|
83
84
|
* @param detectDuplicateDependencies When true, duplicate dependency checking is enabled with a default set of options. Otherwise, the object allows for fine-grained control over the detection process.
|
|
84
85
|
* @param typescriptValidation When true, TypeScript type-checking is enabled with a default set of options. Otherwise, the object allows for fine-grained control over the type-checking process.
|
|
85
86
|
* @param treeShake When true, tree shaking is enabled.
|
|
87
|
+
* @param print Optional function to use when printing status messages to the Metro console
|
|
86
88
|
*/
|
|
87
|
-
function customizeMetroConfig(metroConfigReadonly, detectCyclicDependencies, detectDuplicateDependencies, typescriptValidation, treeShake) {
|
|
89
|
+
function customizeMetroConfig(metroConfigReadonly, detectCyclicDependencies, detectDuplicateDependencies, typescriptValidation, treeShake, print) {
|
|
88
90
|
// We will be making changes to the Metro configuration. Coerce from a
|
|
89
91
|
// type with readonly props to a type where the props are writeable.
|
|
90
92
|
const metroConfig = metroConfigReadonly;
|
|
@@ -123,10 +125,10 @@ function customizeMetroConfig(metroConfigReadonly, detectCyclicDependencies, det
|
|
|
123
125
|
}
|
|
124
126
|
let hook = emptySerializerHook;
|
|
125
127
|
if (typeof typescriptValidation === "object") {
|
|
126
|
-
hook = createSerializerHook(typescriptValidation);
|
|
128
|
+
hook = createSerializerHook(typescriptValidation, print);
|
|
127
129
|
}
|
|
128
130
|
else if (typescriptValidation !== false) {
|
|
129
|
-
hook = createSerializerHook({});
|
|
131
|
+
hook = createSerializerHook({}, print);
|
|
130
132
|
}
|
|
131
133
|
metroConfig.serializer.experimentalSerializerHook = hook;
|
|
132
134
|
}
|
package/lib/metro-config.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metro-config.js","sourceRoot":"","sources":["../src/metro-config.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"metro-config.js","sourceRoot":"","sources":["../src/metro-config.ts"],"names":[],"mappings":";;;AACA,kHAG4D;AAC5D,8FAGkD;AAClD,gEAAyE;AACzE,gFAG2C;AAI3C,8DAAgE;AAKhE;;;;;;;;;;GAUG;AACH,SAAS,oBAAoB,CAC3B,OAAoC,EACpC,KAAiC;IAEjC,MAAM,YAAY,GAAG,IAAA,kCAAkB,EAAC,KAAK,CAAC,CAAC;IAE/C,MAAM,kBAAkB,GAAG,wBAAwB,CAAC;IACpD,MAAM,kBAAkB,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAEtE,MAAM,IAAI,GAAG,CAAC,KAAY,EAAE,KAAkB,EAAQ,EAAE;QACtD,MAAM,QAAQ,GAAG,KAAK,CAAC,gBAAgB,CAAC,QAAwB,CAAC;QACjE,IAAI,QAAQ,EAAE;YACZ,IAAI,KAAK,CAAC,KAAK,EAAE;gBACf,oEAAoE;gBACpE,oEAAoE;gBACpE,gCAAgC;gBAChC,YAAY,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC;aACtC;YAED,uEAAuE;YACvE,8DAA8D;YAC9D,MAAM,IAAI,GAAG,KAAK,CAAC,IAAI,CACrB,KAAK,CAAC,KAAK,CAAC,MAAM,EAAE,EACpB,CAAC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C,IAAA,8DAAkB,GAAE,CAAC,CAAC;KACpC;IAED,IAAI,SAAS,EAAE;QACb,WAAW,CAAC,UAAU,CAAC,gBAAgB,GAAG,IAAA,0CAAsB,EAAC,OAAO,CAAC,CAAC;QAC1E,MAAM,CAAC,MAAM,CAAC,WAAW,CAAC,WAAW,EAAE,mDAAwB,CAAC,CAAC;KAClE;SAAM,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE;QAC7B,qEAAqE;QACrE,oEAAoE;QACpE,gDAAgD;QAChD,EAAE;QACF,kEAAkE;QAClE,sEAAsE;QACtE,mCAAmC;QACnC,EAAE;QACF,kEAAkE;QAClE,wCAAwC;QACxC,WAAW,CAAC,UAAU,CAAC,gBAAgB,GAAG,IAAA,kCAAe,EACvD,OAAO,CACiC,CAAC;KAC5C;SAAM;QACL,OAAO,WAAW,CAAC,UAAU,CAAC,gBAAgB,CAAC;KAChD;IAED,IAAI,IAAI,GAAG,mBAAmB,CAAC;IAC/B,IAAI,OAAO,oBAAoB,KAAK,QAAQ,EAAE;QAC5C,IAAI,GAAG,oBAAoB,CAAC,oBAAoB,EAAE,KAAK,CAAC,CAAC;KAC1D;SAAM,IAAI,oBAAoB,KAAK,KAAK,EAAE;QACzC,IAAI,GAAG,oBAAoB,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;KACxC;IACD,WAAW,CAAC,UAAU,CAAC,0BAA0B,GAAG,IAAI,CAAC;AAC3D,CAAC;AApDD,oDAoDC"}
|
package/lib/parsers.d.ts
CHANGED
package/lib/parsers.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parsers.d.ts","sourceRoot":"","sources":["../src/parsers.ts"],"names":[],"mappings":"AAAA,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAUjD"}
|
|
1
|
+
{"version":3,"file":"parsers.d.ts","sourceRoot":"","sources":["../src/parsers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAEhE,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAUjD;AAED,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,MAAM,GAAG,gBAAgB,CAenE"}
|
package/lib/parsers.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.parseBoolean = void 0;
|
|
3
|
+
exports.parseTransformProfile = exports.parseBoolean = void 0;
|
|
4
4
|
function parseBoolean(val) {
|
|
5
5
|
if (val === "false") {
|
|
6
6
|
return false;
|
|
@@ -11,4 +11,19 @@ function parseBoolean(val) {
|
|
|
11
11
|
throw new Error("Invalid boolean value '" + val + "' -- must be true or false");
|
|
12
12
|
}
|
|
13
13
|
exports.parseBoolean = parseBoolean;
|
|
14
|
+
function parseTransformProfile(val) {
|
|
15
|
+
const allowedProfiles = [
|
|
16
|
+
"hermes-stable",
|
|
17
|
+
"hermes-canary",
|
|
18
|
+
"default",
|
|
19
|
+
];
|
|
20
|
+
if (val in allowedProfiles) {
|
|
21
|
+
return val;
|
|
22
|
+
}
|
|
23
|
+
throw new Error("Invalid transform profile '" +
|
|
24
|
+
val +
|
|
25
|
+
"' -- must be one of " +
|
|
26
|
+
allowedProfiles.join(", "));
|
|
27
|
+
}
|
|
28
|
+
exports.parseTransformProfile = parseTransformProfile;
|
|
14
29
|
//# sourceMappingURL=parsers.js.map
|
package/lib/parsers.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parsers.js","sourceRoot":"","sources":["../src/parsers.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"parsers.js","sourceRoot":"","sources":["../src/parsers.ts"],"names":[],"mappings":";;;AAEA,SAAgB,YAAY,CAAC,GAAW;IACtC,IAAI,GAAG,KAAK,OAAO,EAAE;QACnB,OAAO,KAAK,CAAC;KACd;IACD,IAAI,GAAG,KAAK,MAAM,EAAE;QAClB,OAAO,IAAI,CAAC;KACb;IACD,MAAM,IAAI,KAAK,CACb,yBAAyB,GAAG,GAAG,GAAG,4BAA4B,CAC/D,CAAC;AACJ,CAAC;AAVD,oCAUC;AAED,SAAgB,qBAAqB,CAAC,GAAW;IAC/C,MAAM,eAAe,GAAuB;QAC1C,eAAe;QACf,eAAe;QACf,SAAS;KACV,CAAC;IACF,IAAI,GAAG,IAAI,eAAe,EAAE;QAC1B,OAAO,GAAuB,CAAC;KAChC;IACD,MAAM,IAAI,KAAK,CACb,6BAA6B;QAC3B,GAAG;QACH,sBAAsB;QACtB,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAC7B,CAAC;AACJ,CAAC;AAfD,sDAeC"}
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ServerConfig, BundlerPlugins } from "@rnx-kit/config";
|
|
2
2
|
export declare type ServerConfigOverrides = {
|
|
3
3
|
projectRoot?: string;
|
|
4
4
|
assetPlugins?: string[];
|
|
5
5
|
sourceExts?: string[];
|
|
6
6
|
};
|
|
7
|
+
export declare type CliServerConfig = ServerConfig & Required<BundlerPlugins>;
|
|
7
8
|
/**
|
|
8
|
-
* Get the
|
|
9
|
+
* Get the server configuration from the rnx-kit configuration. Apply any overrides.
|
|
9
10
|
*
|
|
10
|
-
* @param overrides Overrides to apply
|
|
11
|
-
* @returns
|
|
11
|
+
* @param overrides Overrides to apply. These take precedence over the values in the rnx-kit configuration.
|
|
12
|
+
* @returns Server configuration
|
|
12
13
|
*/
|
|
13
|
-
export declare function getKitServerConfig(overrides: ServerConfigOverrides):
|
|
14
|
+
export declare function getKitServerConfig(overrides: ServerConfigOverrides): CliServerConfig;
|
|
14
15
|
//# sourceMappingURL=kit-config.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kit-config.d.ts","sourceRoot":"","sources":["../../src/serve/kit-config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"kit-config.d.ts","sourceRoot":"","sources":["../../src/serve/kit-config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAKpE,oBAAY,qBAAqB,GAAG;IAClC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;CACvB,CAAC;AAEF,oBAAY,eAAe,GAAG,YAAY,GAAG,QAAQ,CAAC,cAAc,CAAC,CAAC;AAEtE;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAChC,SAAS,EAAE,qBAAqB,GAC/B,eAAe,CAqBjB"}
|
package/lib/serve/kit-config.js
CHANGED
|
@@ -2,19 +2,34 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getKitServerConfig = void 0;
|
|
4
4
|
const config_1 = require("@rnx-kit/config");
|
|
5
|
+
const bundler_plugin_defaults_1 = require("../bundler-plugin-defaults");
|
|
5
6
|
const properties_1 = require("@rnx-kit/tools-language/properties");
|
|
6
7
|
/**
|
|
7
|
-
* Get the
|
|
8
|
+
* Get the server configuration from the rnx-kit configuration. Apply any overrides.
|
|
8
9
|
*
|
|
9
|
-
* @param overrides Overrides to apply
|
|
10
|
-
* @returns
|
|
10
|
+
* @param overrides Overrides to apply. These take precedence over the values in the rnx-kit configuration.
|
|
11
|
+
* @returns Server configuration
|
|
11
12
|
*/
|
|
12
13
|
function getKitServerConfig(overrides) {
|
|
13
14
|
const kitConfig = (0, config_1.getKitConfig)();
|
|
14
|
-
|
|
15
|
-
|
|
15
|
+
let serverConfig = kitConfig === null || kitConfig === void 0 ? void 0 : kitConfig.server;
|
|
16
|
+
if (!serverConfig && kitConfig) {
|
|
17
|
+
const maybeBundleConfig = (0, config_1.getBundleConfig)(kitConfig);
|
|
18
|
+
if (maybeBundleConfig) {
|
|
19
|
+
serverConfig = (0, properties_1.pickValues)(maybeBundleConfig, [
|
|
20
|
+
"detectCyclicDependencies",
|
|
21
|
+
"detectDuplicateDependencies",
|
|
22
|
+
"typescriptValidation",
|
|
23
|
+
//"treeShake", // don't pull in treeShake yet, since it doesn't work with the server
|
|
24
|
+
]);
|
|
25
|
+
}
|
|
16
26
|
}
|
|
17
|
-
return
|
|
27
|
+
return {
|
|
28
|
+
...(0, bundler_plugin_defaults_1.getDefaultBundlerPlugins)(),
|
|
29
|
+
...serverConfig,
|
|
30
|
+
treeShake: false,
|
|
31
|
+
...(0, properties_1.pickValues)(overrides, ["projectRoot", "assetPlugins", "sourceExts"]),
|
|
32
|
+
};
|
|
18
33
|
}
|
|
19
34
|
exports.getKitServerConfig = getKitServerConfig;
|
|
20
35
|
//# sourceMappingURL=kit-config.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kit-config.js","sourceRoot":"","sources":["../../src/serve/kit-config.ts"],"names":[],"mappings":";;;AACA,4CAAgE;AAChE,mEAAgE;
|
|
1
|
+
{"version":3,"file":"kit-config.js","sourceRoot":"","sources":["../../src/serve/kit-config.ts"],"names":[],"mappings":";;;AACA,4CAAgE;AAChE,wEAAsE;AACtE,mEAAgE;AAUhE;;;;;GAKG;AACH,SAAgB,kBAAkB,CAChC,SAAgC;IAEhC,MAAM,SAAS,GAAG,IAAA,qBAAY,GAAE,CAAC;IACjC,IAAI,YAAY,GAAG,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,MAAM,CAAC;IACrC,IAAI,CAAC,YAAY,IAAI,SAAS,EAAE;QAC9B,MAAM,iBAAiB,GAAG,IAAA,wBAAe,EAAC,SAAS,CAAC,CAAC;QACrD,IAAI,iBAAiB,EAAE;YACrB,YAAY,GAAG,IAAA,uBAAU,EAAC,iBAAiB,EAAE;gBAC3C,0BAA0B;gBAC1B,6BAA6B;gBAC7B,sBAAsB;gBACtB,qFAAqF;aACtF,CAAC,CAAC;SACJ;KACF;IAED,OAAO;QACL,GAAG,IAAA,kDAAwB,GAAE;QAC7B,GAAG,YAAY;QACf,SAAS,EAAE,KAAK;QAChB,GAAG,IAAA,uBAAU,EAAC,SAAS,EAAE,CAAC,aAAa,EAAE,cAAc,EAAE,YAAY,CAAC,CAAC;KACxE,CAAC;AACJ,CAAC;AAvBD,gDAuBC"}
|
package/lib/start.d.ts
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import type { Config as CLIConfig } from "@react-native-community/cli-types";
|
|
2
2
|
export declare type CLIStartOptions = {
|
|
3
|
-
host: string;
|
|
4
3
|
port: number;
|
|
4
|
+
host: string;
|
|
5
5
|
projectRoot?: string;
|
|
6
6
|
watchFolders?: string[];
|
|
7
7
|
assetPlugins?: string[];
|
|
8
8
|
sourceExts?: string[];
|
|
9
9
|
maxWorkers?: number;
|
|
10
|
+
resetCache?: boolean;
|
|
10
11
|
customLogReporterPath?: string;
|
|
11
12
|
https?: boolean;
|
|
12
13
|
key?: string;
|
|
13
14
|
cert?: string;
|
|
14
|
-
resetCache?: boolean;
|
|
15
15
|
config?: string;
|
|
16
16
|
interactive: boolean;
|
|
17
17
|
};
|
package/lib/start.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"start.d.ts","sourceRoot":"","sources":["../src/start.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,IAAI,SAAS,EAAE,MAAM,mCAAmC,CAAC;AA+B7E,oBAAY,eAAe,GAAG;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,
|
|
1
|
+
{"version":3,"file":"start.d.ts","sourceRoot":"","sources":["../src/start.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,IAAI,SAAS,EAAE,MAAM,mCAAmC,CAAC;AA+B7E,oBAAY,eAAe,GAAG;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,OAAO,CAAC;CACtB,CAAC;AAkBF,wBAAsB,QAAQ,CAC5B,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,EACpB,SAAS,EAAE,SAAS,EACpB,UAAU,EAAE,eAAe,GAC1B,OAAO,CAAC,IAAI,CAAC,CAmMf"}
|
package/lib/start.js
CHANGED
|
@@ -1,13 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
4
|
};
|
|
@@ -29,166 +20,163 @@ function friendlyRequire(module) {
|
|
|
29
20
|
throw new Error(`Cannot find module '${module}'. This probably means that '@rnx-kit/cli' is not compatible with the version of '@react-native-community/cli' that you are currently using. Please update to the latest version and try again. If the issue still persists after the update, please file a bug at https://github.com/microsoft/rnx-kit/issues.`);
|
|
30
21
|
}
|
|
31
22
|
}
|
|
32
|
-
function
|
|
33
|
-
return
|
|
23
|
+
function hasAttachToServerFunction(devServer) {
|
|
24
|
+
return "attachToServer" in devServer;
|
|
34
25
|
}
|
|
35
|
-
function rnxStart(_argv, cliConfig, cliOptions) {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
26
|
+
async function rnxStart(_argv, cliConfig, cliOptions) {
|
|
27
|
+
const serverConfig = (0, kit_config_1.getKitServerConfig)(cliOptions);
|
|
28
|
+
const { createDevServerMiddleware, indexPageMiddleware } = friendlyRequire("@react-native-community/cli-server-api");
|
|
29
|
+
// interactive mode requires raw access to stdin
|
|
30
|
+
let interactive = cliOptions.interactive;
|
|
31
|
+
if (interactive) {
|
|
32
|
+
interactive = process.stdin.isTTY;
|
|
33
|
+
if (!interactive) {
|
|
34
|
+
console.warn(chalk_1.default.yellow("Warning: Interactive mode is not supported on this terminal"));
|
|
40
35
|
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
36
|
+
}
|
|
37
|
+
// create a Metro terminal and reporter for writing to the console
|
|
38
|
+
const { terminal, reporter: terminalReporter } = (0, metro_service_1.createTerminal)(cliOptions.customLogReporterPath);
|
|
39
|
+
// create a reporter function, to be bound to the Metro configuration.
|
|
40
|
+
// which writes to the Metro terminal and
|
|
41
|
+
// also notifies the `reportEvent` delegate.
|
|
42
|
+
let reportEventDelegate = undefined;
|
|
43
|
+
const reporter = {
|
|
44
|
+
update(event) {
|
|
45
|
+
terminalReporter.update(event);
|
|
46
|
+
if (reportEventDelegate) {
|
|
47
|
+
reportEventDelegate(event);
|
|
48
48
|
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
["d", "open developer menu"],
|
|
68
|
-
["a", "show bundler address QR code"],
|
|
69
|
-
["ctrl-c", "quit"],
|
|
70
|
-
].forEach(([key, description]) => {
|
|
71
|
-
terminal.log(press + key + dim(` to ${description}.`));
|
|
72
|
-
});
|
|
73
|
-
}
|
|
74
|
-
},
|
|
75
|
-
};
|
|
76
|
-
// load Metro configuration, applying overrides from the command line
|
|
77
|
-
const metroConfig = yield (0, metro_service_1.loadMetroConfig)(cliConfig, Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, cliOptions), (serverConfig.projectRoot
|
|
49
|
+
if (interactive && event.type === "dep_graph_loading") {
|
|
50
|
+
const dim = chalk_1.default.dim;
|
|
51
|
+
const press = dim(" › Press ");
|
|
52
|
+
[
|
|
53
|
+
["r", "reload the app"],
|
|
54
|
+
["d", "open developer menu"],
|
|
55
|
+
["a", "show bundler address QR code"],
|
|
56
|
+
["ctrl-c", "quit"],
|
|
57
|
+
].forEach(([key, description]) => {
|
|
58
|
+
terminal.log(press + key + dim(` to ${description}.`));
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
},
|
|
62
|
+
};
|
|
63
|
+
// load Metro configuration, applying overrides from the command line
|
|
64
|
+
const metroConfig = await (0, metro_service_1.loadMetroConfig)(cliConfig, {
|
|
65
|
+
...cliOptions,
|
|
66
|
+
...(serverConfig.projectRoot
|
|
78
67
|
? { projectRoot: path_1.default.resolve(serverConfig.projectRoot) }
|
|
79
|
-
: undefined)
|
|
68
|
+
: undefined),
|
|
69
|
+
reporter,
|
|
70
|
+
...(serverConfig.sourceExts
|
|
80
71
|
? { sourceExts: serverConfig.sourceExts }
|
|
81
|
-
: undefined)
|
|
72
|
+
: undefined),
|
|
73
|
+
...(serverConfig.assetPlugins
|
|
82
74
|
? {
|
|
83
75
|
assetPlugins: serverConfig.assetPlugins.map((p) => require.resolve(p)),
|
|
84
76
|
}
|
|
85
|
-
: undefined)
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
};
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
case "z":
|
|
161
|
-
process.emit("SIGTSTP", "SIGTSTP");
|
|
162
|
-
break;
|
|
163
|
-
}
|
|
77
|
+
: undefined),
|
|
78
|
+
});
|
|
79
|
+
// customize the metro config to include plugins, presets, etc.
|
|
80
|
+
(0, metro_config_1.customizeMetroConfig)(metroConfig, serverConfig.detectCyclicDependencies, serverConfig.detectDuplicateDependencies, serverConfig.typescriptValidation, serverConfig.treeShake, (message) => {
|
|
81
|
+
terminal.log(message);
|
|
82
|
+
});
|
|
83
|
+
// create middleware -- a collection of plugins which handle incoming
|
|
84
|
+
// http(s) requests, routing them to static pages or JS functions.
|
|
85
|
+
const devServer = createDevServerMiddleware({
|
|
86
|
+
host: cliOptions.host,
|
|
87
|
+
port: metroConfig.server.port,
|
|
88
|
+
watchFolders: metroConfig.watchFolders,
|
|
89
|
+
});
|
|
90
|
+
const middleware = devServer.middleware;
|
|
91
|
+
middleware.use(indexPageMiddleware);
|
|
92
|
+
// merge the Metro config middleware with our middleware
|
|
93
|
+
const enhanceMiddleware = metroConfig.server.enhanceMiddleware;
|
|
94
|
+
// @ts-expect-error We want to assign to read-only `enhanceMiddleware`
|
|
95
|
+
metroConfig.server.enhanceMiddleware = (metroMiddleware, metroServer) => {
|
|
96
|
+
return middleware.use(enhanceMiddleware
|
|
97
|
+
? enhanceMiddleware(metroMiddleware, metroServer)
|
|
98
|
+
: metroMiddleware);
|
|
99
|
+
};
|
|
100
|
+
// `createDevServerMiddleware` changed its return type in
|
|
101
|
+
// https://github.com/react-native-community/cli/pull/1560
|
|
102
|
+
let websocketEndpoints = undefined;
|
|
103
|
+
let messageSocketEndpoint;
|
|
104
|
+
if (!hasAttachToServerFunction(devServer)) {
|
|
105
|
+
websocketEndpoints = devServer.websocketEndpoints;
|
|
106
|
+
messageSocketEndpoint = devServer.messageSocketEndpoint;
|
|
107
|
+
// bind our `reportEvent` delegate to the Metro server
|
|
108
|
+
reportEventDelegate = devServer.eventsSocketEndpoint.reportEvent;
|
|
109
|
+
}
|
|
110
|
+
// start the Metro server
|
|
111
|
+
const serverOptions = {
|
|
112
|
+
host: cliOptions.host,
|
|
113
|
+
secure: cliOptions.https,
|
|
114
|
+
secureCert: cliOptions.cert,
|
|
115
|
+
secureKey: cliOptions.key,
|
|
116
|
+
websocketEndpoints,
|
|
117
|
+
};
|
|
118
|
+
const serverInstance = await (0, metro_service_1.startServer)(metroConfig, serverOptions);
|
|
119
|
+
if (hasAttachToServerFunction(devServer)) {
|
|
120
|
+
const { messageSocket, eventsSocket } = devServer.attachToServer(serverInstance);
|
|
121
|
+
messageSocketEndpoint = messageSocket;
|
|
122
|
+
// bind our `reportEvent` delegate to the Metro server
|
|
123
|
+
reportEventDelegate = eventsSocket.reportEvent;
|
|
124
|
+
}
|
|
125
|
+
// In Node 8, the default keep-alive for an HTTP connection is 5 seconds. In
|
|
126
|
+
// early versions of Node 8, this was implemented in a buggy way which caused
|
|
127
|
+
// some HTTP responses (like those containing large JS bundles) to be
|
|
128
|
+
// terminated early.
|
|
129
|
+
//
|
|
130
|
+
// As a workaround, arbitrarily increase the keep-alive from 5 to 30 seconds,
|
|
131
|
+
// which should be enough to send even the largest of JS bundles.
|
|
132
|
+
//
|
|
133
|
+
// For more info: https://github.com/nodejs/node/issues/13391
|
|
134
|
+
//
|
|
135
|
+
serverInstance.keepAliveTimeout = 30000;
|
|
136
|
+
// in interactive mode, listen for keyboard events from stdin and bind
|
|
137
|
+
// them to specific actions.
|
|
138
|
+
if (interactive) {
|
|
139
|
+
readline_1.default.emitKeypressEvents(process.stdin);
|
|
140
|
+
process.stdin.setRawMode(true);
|
|
141
|
+
process.stdin.on("keypress", (_key, data) => {
|
|
142
|
+
const { ctrl, name } = data;
|
|
143
|
+
if (ctrl === true) {
|
|
144
|
+
switch (name) {
|
|
145
|
+
case "c":
|
|
146
|
+
terminal.log(chalk_1.default.green("Exiting..."));
|
|
147
|
+
process.exit();
|
|
148
|
+
break;
|
|
149
|
+
case "z":
|
|
150
|
+
process.emit("SIGTSTP", "SIGTSTP");
|
|
151
|
+
break;
|
|
164
152
|
}
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
case "d":
|
|
180
|
-
terminal.log(chalk_1.default.green("Opening developer menu..."));
|
|
181
|
-
messageSocketEndpoint.broadcast("devMenu", undefined);
|
|
182
|
-
break;
|
|
183
|
-
case "r":
|
|
184
|
-
terminal.log(chalk_1.default.green("Reloading app..."));
|
|
185
|
-
messageSocketEndpoint.broadcast("reload", undefined);
|
|
186
|
-
break;
|
|
153
|
+
}
|
|
154
|
+
else {
|
|
155
|
+
switch (name) {
|
|
156
|
+
case "a": {
|
|
157
|
+
const protocol = cliOptions.https ? "https" : "http";
|
|
158
|
+
const host = cliOptions.host || os_1.default.hostname();
|
|
159
|
+
const port = metroConfig.server.port;
|
|
160
|
+
const url = `${protocol}://${host}:${port}/index.bundle`;
|
|
161
|
+
qrcode_1.default.toString(url, { type: "terminal" }, (_err, qr) => {
|
|
162
|
+
terminal.log("");
|
|
163
|
+
terminal.log(url + ":");
|
|
164
|
+
terminal.log(qr);
|
|
165
|
+
});
|
|
166
|
+
break;
|
|
187
167
|
}
|
|
168
|
+
case "d":
|
|
169
|
+
terminal.log(chalk_1.default.green("Opening developer menu..."));
|
|
170
|
+
messageSocketEndpoint.broadcast("devMenu", undefined);
|
|
171
|
+
break;
|
|
172
|
+
case "r":
|
|
173
|
+
terminal.log(chalk_1.default.green("Reloading app..."));
|
|
174
|
+
messageSocketEndpoint.broadcast("reload", undefined);
|
|
175
|
+
break;
|
|
188
176
|
}
|
|
189
|
-
}
|
|
190
|
-
}
|
|
191
|
-
}
|
|
177
|
+
}
|
|
178
|
+
});
|
|
179
|
+
}
|
|
192
180
|
}
|
|
193
181
|
exports.rnxStart = rnxStart;
|
|
194
182
|
//# sourceMappingURL=start.js.map
|
package/lib/start.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"start.js","sourceRoot":"","sources":["../src/start.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"start.js","sourceRoot":"","sources":["../src/start.ts"],"names":[],"mappings":";;;;;;AAEA,0DAIgC;AAChC,kDAA0B;AAM1B,4CAAoB;AACpB,gDAAwB;AACxB,oDAA4B;AAC5B,wDAAgC;AAChC,iDAAsD;AACtD,mDAAwD;AA+BxD,SAAS,eAAe,CAAI,MAAc;IACxC,IAAI;QACF,OAAO,OAAO,CAAC,MAAM,CAAM,CAAC;KAC7B;IAAC,OAAO,CAAC,EAAE;QACV,MAAM,IAAI,KAAK,CACb,uBAAuB,MAAM,iTAAiT,CAC/U,CAAC;KACH;AACH,CAAC;AAED,SAAS,yBAAyB,CAChC,SAAqD;IAErD,OAAO,gBAAgB,IAAI,SAAS,CAAC;AACvC,CAAC;AAEM,KAAK,UAAU,QAAQ,CAC5B,KAAoB,EACpB,SAAoB,EACpB,UAA2B;IAE3B,MAAM,YAAY,GAAG,IAAA,+BAAkB,EAAC,UAAU,CAAC,CAAC;IAEpD,MAAM,EAAE,yBAAyB,EAAE,mBAAmB,EAAE,GAAG,eAAe,CAExE,wCAAwC,CAAC,CAAC;IAE5C,gDAAgD;IAChD,IAAI,WAAW,GAAG,UAAU,CAAC,WAAW,CAAC;IACzC,IAAI,WAAW,EAAE;QACf,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC;QAClC,IAAI,CAAC,WAAW,EAAE;YAChB,OAAO,CAAC,IAAI,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