* Initializes handling of ES modules. * @param {boolean} [shouldSpawnLoaderHookWorker] Whether the custom loader worker * should be spawned later.
(shouldSpawnLoaderHookWorker = true)
| 301 | * should be spawned later. |
| 302 | */ |
| 303 | function initializeESM(shouldSpawnLoaderHookWorker = true) { |
| 304 | _shouldSpawnLoaderHookWorker = shouldSpawnLoaderHookWorker; |
| 305 | initializeDefaultConditions(); |
| 306 | // Setup per-realm callbacks that locate data or callbacks that we keep |
| 307 | // track of for different ESM modules. |
| 308 | setInitializeImportMetaObjectCallback(initializeImportMetaObject); |
| 309 | setImportModuleDynamicallyCallback(importModuleDynamicallyCallback); |
| 310 | } |
| 311 | |
| 312 | /** |
| 313 | * Determine whether the custom loader worker should be spawned when initializing |
no test coverage detected
searching dependent graphs…