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

Method setExport

lib/internal/vm/module.js:499–506  ·  view source on GitHub ↗
(name, value)

Source from the content-addressed store, hash-verified

497 }
498
499 setExport(name, value) {
500 validateThisInternalField(this, kWrap, 'SyntheticModule');
501 validateString(name, 'name');
502 if (this[kWrap].getStatus() < kInstantiated) {
503 throw new ERR_VM_MODULE_STATUS('must be linked');
504 }
505 this[kWrap].setExport(name, value);
506 }
507}
508
509/**

Callers 9

createSyntheticModuleFunction · 0.95
importModuleDynamicallyFunction · 0.95
createCJSModuleWrapFunction · 0.80
translators.jsFile · 0.80
getESMFacadeMethod · 0.80
syncExportsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected