MCPcopy Index your code
hub / github.com/nodejs/node / syncExports

Method syncExports

lib/internal/bootstrap/realm.js:380–390  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

378 // as the entire namespace (module.exports) and updates when this function is
379 // called so that APMs and other behavior are supported.
380 syncExports() {
381 const names = this.exportKeys;
382 if (this.module) {
383 for (let i = 0; i < names.length; i++) {
384 const exportName = names[i];
385 if (exportName === 'default') continue;
386 this.module.setExport(exportName,
387 getOwn(this.exports, exportName, this.exports));
388 }
389 }
390 }
391
392 compileForInternalLoader() {
393 if (this.loaded || this.loading) {

Callers 2

loader.jsFile · 0.80
getESMFacadeMethod · 0.80

Calls 2

getOwnFunction · 0.85
setExportMethod · 0.80

Tested by

no test coverage detected