metro 0.80.4 → 0.80.6

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.
Files changed (149) hide show
  1. package/package.json +16 -17
  2. package/src/Assets.js +0 -35
  3. package/src/Bundler/util.js +1 -29
  4. package/src/Bundler.js +1 -20
  5. package/src/DeltaBundler/DeltaCalculator.js +0 -86
  6. package/src/DeltaBundler/Graph.js +0 -197
  7. package/src/DeltaBundler/Serializers/baseJSBundle.js +0 -13
  8. package/src/DeltaBundler/Serializers/getAllFiles.js +0 -11
  9. package/src/DeltaBundler/Serializers/getAssets.js +0 -11
  10. package/src/DeltaBundler/Serializers/getExplodedSourceMap.js +0 -11
  11. package/src/DeltaBundler/Serializers/getRamBundleInfo.js +0 -18
  12. package/src/DeltaBundler/Serializers/helpers/getInlineSourceMappingURL.js +0 -11
  13. package/src/DeltaBundler/Serializers/helpers/getSourceMapInfo.js +0 -11
  14. package/src/DeltaBundler/Serializers/helpers/getTransitiveDependencies.js +0 -14
  15. package/src/DeltaBundler/Serializers/helpers/js.js +0 -21
  16. package/src/DeltaBundler/Serializers/helpers/processModules.js +0 -11
  17. package/src/DeltaBundler/Serializers/hmrJSBundle.js +0 -23
  18. package/src/DeltaBundler/Serializers/sourceMapGenerator.js +0 -16
  19. package/src/DeltaBundler/Serializers/sourceMapObject.js +0 -11
  20. package/src/DeltaBundler/Serializers/sourceMapString.js +0 -11
  21. package/src/DeltaBundler/Transformer.js +0 -30
  22. package/src/DeltaBundler/Worker.flow.js +0 -26
  23. package/src/DeltaBundler/Worker.flow.js.flow +2 -2
  24. package/src/DeltaBundler/Worker.js +0 -14
  25. package/src/DeltaBundler/WorkerFarm.js +1 -21
  26. package/src/DeltaBundler/__fixtures__/hasteImpl.js +0 -14
  27. package/src/DeltaBundler/buildSubgraph.js +0 -24
  28. package/src/DeltaBundler/getTransformCacheKey.js +0 -13
  29. package/src/DeltaBundler/getTransformCacheKey.js.flow +1 -1
  30. package/src/DeltaBundler/mergeDeltas.js +0 -11
  31. package/src/DeltaBundler/types.flow.js +0 -11
  32. package/src/DeltaBundler.js +0 -21
  33. package/src/HmrServer.js +8 -39
  34. package/src/HmrServer.js.flow +8 -6
  35. package/src/IncrementalBundler/GraphNotFoundError.js +0 -11
  36. package/src/IncrementalBundler/ResourceNotFoundError.js +0 -11
  37. package/src/IncrementalBundler/RevisionNotFoundError.js +0 -11
  38. package/src/IncrementalBundler.js +0 -23
  39. package/src/ModuleGraph/test-helpers.js +0 -17
  40. package/src/ModuleGraph/worker/JsFileWrapping.js +1 -22
  41. package/src/ModuleGraph/worker/collectDependencies.js +1 -94
  42. package/src/ModuleGraph/worker/generateImportNames.js +0 -15
  43. package/src/Server/MultipartResponse.js +0 -13
  44. package/src/Server/symbolicate.js +2 -36
  45. package/src/Server.js +6 -83
  46. package/src/cli/parseKeyValueParamArray.js +0 -11
  47. package/src/cli-utils.js +0 -11
  48. package/src/cli.js +0 -13
  49. package/src/commands/build.js +0 -15
  50. package/src/commands/dependencies.js +1 -19
  51. package/src/commands/serve.js +0 -19
  52. package/src/index.flow.js +0 -31
  53. package/src/index.js +0 -14
  54. package/src/integration_tests/basic_bundle/AssetRegistry.js +0 -10
  55. package/src/integration_tests/basic_bundle/Bar.js +0 -10
  56. package/src/integration_tests/basic_bundle/ErrorBundle.js +0 -12
  57. package/src/integration_tests/basic_bundle/Foo.js +0 -10
  58. package/src/integration_tests/basic_bundle/TestBigInt.js +0 -12
  59. package/src/integration_tests/basic_bundle/TestBundle.js +0 -11
  60. package/src/integration_tests/basic_bundle/TestPolyfill.js +0 -10
  61. package/src/integration_tests/basic_bundle/build-errors/cannot-resolve-import.js +0 -14
  62. package/src/integration_tests/basic_bundle/build-errors/cannot-resolve-multi-line-import-with-escapes.js +0 -14
  63. package/src/integration_tests/basic_bundle/build-errors/cannot-resolve-multi-line-import.js +0 -14
  64. package/src/integration_tests/basic_bundle/build-errors/cannot-resolve-require-with-embedded-comment.js +1 -15
  65. package/src/integration_tests/basic_bundle/build-errors/cannot-resolve-require.js +0 -13
  66. package/src/integration_tests/basic_bundle/build-errors/cannot-resolve-specifier-with-escapes.js +0 -16
  67. package/src/integration_tests/basic_bundle/build-errors/inline-requires-cannot-resolve-import.js +0 -14
  68. package/src/integration_tests/basic_bundle/build-errors/inline-requires-cannot-resolve-require.js +0 -13
  69. package/src/integration_tests/basic_bundle/import-export/export-1.js +0 -10
  70. package/src/integration_tests/basic_bundle/import-export/export-2.js +0 -10
  71. package/src/integration_tests/basic_bundle/import-export/export-3.js +0 -10
  72. package/src/integration_tests/basic_bundle/import-export/export-4.js +0 -10
  73. package/src/integration_tests/basic_bundle/import-export/export-5.js +0 -10
  74. package/src/integration_tests/basic_bundle/import-export/export-6.js +0 -10
  75. package/src/integration_tests/basic_bundle/import-export/export-null.js +0 -10
  76. package/src/integration_tests/basic_bundle/import-export/export-primitive-default.js +0 -10
  77. package/src/integration_tests/basic_bundle/import-export/index.js +0 -10
  78. package/src/integration_tests/basic_bundle/loadBundleAsyncForTest.js +0 -10
  79. package/src/integration_tests/basic_bundle/polyfill.js +0 -12
  80. package/src/integration_tests/basic_bundle/require-context/conflict.js +0 -10
  81. package/src/integration_tests/basic_bundle/require-context/empty.js +0 -10
  82. package/src/integration_tests/basic_bundle/require-context/matching.js +0 -10
  83. package/src/integration_tests/basic_bundle/require-context/mode-eager.js +0 -10
  84. package/src/integration_tests/basic_bundle/require-context/mode-lazy-once.js +0 -10
  85. package/src/integration_tests/basic_bundle/require-context/mode-lazy.js +0 -10
  86. package/src/integration_tests/basic_bundle/require-context/mode-sync.js +0 -11
  87. package/src/integration_tests/basic_bundle/require-context/subdir/a.js +0 -10
  88. package/src/integration_tests/basic_bundle/require-context/subdir/b.js +0 -9
  89. package/src/integration_tests/basic_bundle/require-context/subdir/c.js +0 -10
  90. package/src/integration_tests/basic_bundle/require-context/subdir/nested/d.js +0 -10
  91. package/src/integration_tests/basic_bundle/require-context/subdir-conflict/index.js +0 -10
  92. package/src/integration_tests/basic_bundle/require-context/utils.js +0 -10
  93. package/src/integration_tests/basic_bundle/require-resolveWeak/import-and-resolveWeak.js +0 -15
  94. package/src/integration_tests/basic_bundle/require-resolveWeak/multiple.js +0 -10
  95. package/src/integration_tests/basic_bundle/require-resolveWeak/never-required.js +0 -10
  96. package/src/integration_tests/basic_bundle/require-resolveWeak/require-and-resolveWeak.js +0 -15
  97. package/src/integration_tests/basic_bundle/require-resolveWeak/subdir/counter-module.js +0 -10
  98. package/src/integration_tests/basic_bundle/require-resolveWeak/subdir/throwing-module.js +0 -10
  99. package/src/integration_tests/execBundle.js +0 -11
  100. package/src/integration_tests/metro.config.js +0 -10
  101. package/src/lib/BatchProcessor.js +0 -23
  102. package/src/lib/CountingSet.js +0 -35
  103. package/src/lib/JsonReporter.js +0 -17
  104. package/src/lib/RamBundleParser.js +0 -23
  105. package/src/lib/TerminalReporter.js +0 -68
  106. package/src/lib/bundleToString.js +1 -19
  107. package/src/lib/contextModule.js +1 -31
  108. package/src/lib/contextModuleTemplates.js +0 -36
  109. package/src/lib/countLines.js +0 -11
  110. package/src/lib/createModuleIdFactory.js +0 -11
  111. package/src/lib/createWebsocketServer.js +0 -24
  112. package/src/lib/debounceAsyncQueue.js +0 -13
  113. package/src/lib/formatBundlingError.js +0 -14
  114. package/src/lib/getAppendScripts.js +0 -11
  115. package/src/lib/getGraphId.js +0 -11
  116. package/src/lib/getMaxWorkers.js +0 -11
  117. package/src/lib/getPreludeCode.js +0 -18
  118. package/src/lib/getPrependedScripts.js +0 -13
  119. package/src/lib/logToConsole.js +0 -18
  120. package/src/lib/parseCustomResolverOptions.js +0 -11
  121. package/src/lib/parseCustomTransformOptions.js +0 -12
  122. package/src/lib/parseOptionsFromUrl.js +1 -17
  123. package/src/lib/relativizeSourceMap.js +0 -12
  124. package/src/lib/reporting.js +0 -30
  125. package/src/lib/splitBundleOptions.js +0 -14
  126. package/src/lib/transformHelpers.js +0 -20
  127. package/src/node-haste/DependencyGraph/ModuleResolution.js +5 -64
  128. package/src/node-haste/DependencyGraph/createFileMap.js +0 -16
  129. package/src/node-haste/DependencyGraph.js +6 -46
  130. package/src/node-haste/DependencyGraph.js.flow +7 -4
  131. package/src/node-haste/Module.js +0 -11
  132. package/src/node-haste/ModuleCache.js +0 -20
  133. package/src/node-haste/Package.js +0 -11
  134. package/src/node-haste/lib/AssetPaths.js +0 -16
  135. package/src/node-haste/lib/parsePlatformFilePath.js +0 -16
  136. package/src/shared/output/RamBundle/as-assets.js +6 -29
  137. package/src/shared/output/RamBundle/as-indexed-file.js +0 -44
  138. package/src/shared/output/RamBundle/buildSourcemapWithMetadata.js +0 -13
  139. package/src/shared/output/RamBundle/magic-number.js +0 -11
  140. package/src/shared/output/RamBundle/util.js +1 -17
  141. package/src/shared/output/RamBundle/write-sourcemap.js +0 -12
  142. package/src/shared/output/RamBundle.js +0 -14
  143. package/src/shared/output/bundle.flow.js +0 -13
  144. package/src/shared/output/bundle.flow.js.flow +1 -1
  145. package/src/shared/output/bundle.js +0 -14
  146. package/src/shared/output/meta.js +0 -11
  147. package/src/shared/output/unbundle.js +0 -13
  148. package/src/shared/output/writeFile.js +0 -11
  149. package/src/shared/types.flow.js +0 -11
@@ -1,18 +1,4 @@
1
1
  "use strict";
2
2
 
3
3
  var _doesNotExist = require("./does-not-exist");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- *
11
- * @format
12
- */
13
-
14
- /* eslint-disable no-unused-vars */
15
-
16
- // $FlowExpectedError[cannot-resolve-module]
17
-
18
4
  global.x = _doesNotExist.aaaaaaaaaa;
@@ -1,18 +1,4 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- *
10
- * @format
11
- */
12
-
13
- // $FlowExpectedError[cannot-resolve-module]
14
-
15
- // $FlowExpectedError[cannot-resolve-module]
16
- const DoesNotExist = require("./foo" /* ./foo */);
17
-
3
+ const DoesNotExist = require("./foo");
18
4
  global.x = DoesNotExist;
@@ -1,17 +1,4 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- *
10
- * @format
11
- */
12
-
13
- // $FlowExpectedError[cannot-resolve-module]
14
-
15
- // $FlowExpectedError[cannot-resolve-module]
16
3
  const DoesNotExist = require("./does-not-exist");
17
4
  global.x = DoesNotExist;
@@ -1,20 +1,4 @@
1
1
  "use strict";
2
2
 
3
3
  var _doesNotExist = require("./does-not'\"-exist");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- *
11
- * @format
12
- */
13
-
14
- /* eslint-disable no-unused-vars */
15
-
16
- // $FlowExpectedError[cannot-resolve-module]
17
-
18
- // $FlowExpectedError[cannot-resolve-module]
19
-
20
4
  global.x = _doesNotExist.DoesNotExist;
@@ -4,18 +4,4 @@ var _doesNotExist = _interopRequireDefault(require("./does-not-exist"));
4
4
  function _interopRequireDefault(obj) {
5
5
  return obj && obj.__esModule ? obj : { default: obj };
6
6
  }
7
- /**
8
- * Copyright (c) Meta Platforms, Inc. and affiliates.
9
- *
10
- * This source code is licensed under the MIT license found in the
11
- * LICENSE file in the root directory of this source tree.
12
- *
13
- *
14
- * @format
15
- */
16
-
17
- // $FlowExpectedError[cannot-resolve-module]
18
-
19
- // $FlowExpectedError[cannot-resolve-module]
20
-
21
7
  global.x = _doesNotExist.default;
@@ -1,17 +1,4 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- *
10
- * @format
11
- */
12
-
13
- // $FlowExpectedError[cannot-resolve-module]
14
-
15
- // $FlowExpectedError[cannot-resolve-module]
16
3
  const DoesNotExist = require("./does-not-exist");
17
4
  global.x = DoesNotExist;
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  module.exports = {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- *
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  Object.defineProperty(exports, "__esModule", {
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- *
8
- * @format
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  const key = `${global.__METRO_GLOBAL_PREFIX__ ?? ""}__loadBundleAsync`;
@@ -1,15 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- * @oncall react_native
9
- */
10
-
11
1
  "use strict";
12
2
 
13
- // Inject something into the global object so we can verify that this file
14
- // is indeed evaluated.
15
3
  global.POLYFILL_IS_INJECTED = "POLYFILL_IS_INJECTED";
@@ -1,16 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  var _utils = require("./utils");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- * @format
11
- *
12
- */
13
-
14
4
  const normalModule = require("./subdir-conflict");
15
5
  const contextModule = require.context("./subdir-conflict");
16
6
  function main() {
@@ -1,15 +1,5 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  const empty = require.context("./no-such-dir");
14
4
  function main() {
15
5
  try {
@@ -1,15 +1,5 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  const ab = require.context("./subdir", false, /\/(a|b)\.js$/);
14
4
  const abc = require.context("./subdir", false);
15
5
  const abcd = require.context("./subdir", true);
@@ -1,16 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  var _utils = require("./utils");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- * @format
11
- *
12
- */
13
-
14
4
  function main() {
15
5
  return (0, _utils.awaitProperties)(
16
6
  (0, _utils.copyContextToObject)(
@@ -1,16 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  var _utils = require("./utils");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- * @format
11
- *
12
- */
13
-
14
4
  function main() {
15
5
  return (0, _utils.awaitProperties)(
16
6
  (0, _utils.copyContextToObject)(
@@ -1,16 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  var _utils = require("./utils");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- * @format
11
- *
12
- */
13
-
14
4
  function main() {
15
5
  return (0, _utils.awaitProperties)(
16
6
  (0, _utils.copyContextToObject)(
@@ -1,19 +1,8 @@
1
1
  "use strict";
2
2
 
3
3
  var _utils = require("./utils");
4
- /**
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- *
10
- * @format
11
- *
12
- */
13
-
14
4
  function main() {
15
5
  return (0, _utils.copyContextToObject)(
16
- // $FlowFixMe[underconstrained-implicit-instantiation]
17
6
  require.context("./subdir", undefined, undefined, "sync")
18
7
  );
19
8
  }
@@ -1,13 +1,3 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  module.exports = "a";
@@ -4,14 +4,5 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true,
5
5
  });
6
6
  exports.default = void 0;
7
- /**
8
- * Copyright (c) Meta Platforms, Inc. and affiliates.
9
- *
10
- * This source code is licensed under the MIT license found in the
11
- * LICENSE file in the root directory of this source tree.
12
- *
13
- * @format
14
- *
15
- */
16
7
  var _default = "b";
17
8
  exports.default = _default;
@@ -1,13 +1,3 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  module.exports = "c";
@@ -1,13 +1,3 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  module.exports = "d";
@@ -1,13 +1,3 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  module.exports = "contents of subdir-conflict/index.js";
@@ -5,16 +5,6 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.awaitProperties = awaitProperties;
7
7
  exports.copyContextToObject = copyContextToObject;
8
- /**
9
- * Copyright (c) Meta Platforms, Inc. and affiliates.
10
- *
11
- * This source code is licensed under the MIT license found in the
12
- * LICENSE file in the root directory of this source tree.
13
- *
14
- * @format
15
- *
16
- */
17
-
18
8
  function copyContextToObject(ctx) {
19
9
  return Object.fromEntries(ctx.keys().map((key) => [key, ctx(key)]));
20
10
  }
@@ -1,27 +1,12 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  async function main() {
14
4
  const moduleId = require.resolveWeak("./subdir/counter-module");
15
-
16
- // Require the module statically via its path, spelled slightly differently
17
5
  (await import("./subdir/counter-module.js")).increment();
18
6
  const dynamicRequire = require;
19
-
20
- // Require the module dynamically via its ID
21
7
  const timesIncremented = dynamicRequire(moduleId).increment();
22
8
  return {
23
9
  moduleId,
24
- // Should be 2, proving there's just one module instance
25
10
  timesIncremented,
26
11
  };
27
12
  }
@@ -1,15 +1,5 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  async function main() {
14
4
  return {
15
5
  counterModuleId1: require.resolveWeak("./subdir/counter-module"),
@@ -1,15 +1,5 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  function main() {
14
4
  return {
15
5
  moduleId: require.resolveWeak("./subdir/throwing-module"),
@@ -1,27 +1,12 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  function main() {
14
4
  const moduleId = require.resolveWeak("./subdir/counter-module");
15
5
  const dynamicRequire = require;
16
-
17
- // Require the module dynamically via its ID
18
6
  dynamicRequire(moduleId).increment();
19
-
20
- // Require the module statically via its path, spelled slightly differently
21
7
  const timesIncremented = require("./subdir/counter-module.js").increment();
22
8
  return {
23
9
  moduleId,
24
- // Should be 2, proving there's just one module instance
25
10
  timesIncremented,
26
11
  };
27
12
  }
@@ -1,15 +1,5 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  let count = 0;
14
4
  module.exports = {
15
5
  increment() {
@@ -1,13 +1,3 @@
1
1
  "use strict";
2
2
 
3
- /**
4
- * Copyright (c) Meta Platforms, Inc. and affiliates.
5
- *
6
- * This source code is licensed under the MIT license found in the
7
- * LICENSE file in the root directory of this source tree.
8
- *
9
- * @format
10
- *
11
- */
12
-
13
3
  throw new Error("This module cannot be evaluated.");
@@ -1,14 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- *
8
- * @format
9
- * @oncall react_native
10
- */
11
-
12
1
  "use strict";
13
2
 
14
3
  const vm = require("vm");
@@ -1,13 +1,3 @@
1
- /**
2
- * Copyright (c) Meta Platforms, Inc. and affiliates.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- *
7
- * @format
8
- * @oncall react_native
9
- */
10
-
11
1
  "use strict";
12
2
 
13
3
  const path = require("path");