(...names: string[])
| 620 | } & unknown |
| 621 | > |
| 622 | export(...names: string[]): SchemaModule { |
| 623 | if (!this._exports) { |
| 624 | this._exports = {} |
| 625 | for (const name of this.exportedNames) { |
| 626 | const def = this.aliases[name] |
| 627 | this._exports[name] = |
| 628 | hasArkKind(def, "module") ? |
| 629 | bindModule(def, this) |
| 630 | : bootstrapAliasReferences(this.maybeResolve(name)!) |
| 631 | } |
| 632 | |
| 633 | // force node.resolution getter evaluation |
| 634 | // eslint-disable-next-line @typescript-eslint/no-unused-expressions |
| 635 | for (const node of this.lazyResolutions) node.resolution |
| 636 | |
| 637 | this._exportedResolutions = resolutionsOfModule(this, this._exports) |
| 638 | |
| 639 | this._json = resolutionsToJson(this._exportedResolutions) |
| 640 | Object.assign(this.resolutions, this._exportedResolutions) |
| 641 | |
| 642 | this.references = Object.values(this.referencesById) |
| 643 | if (!this.resolvedConfig.jitless) { |
| 644 | const precompiler = precompileReferences(this.references) |
| 645 | this.precompilation = precompiler.write(rootScopeFnName, 4) |
| 646 | bindPrecompilation(this.references, precompiler, this) |
| 647 | } |
| 648 | this.resolved = true |
| 649 | } |
| 650 | const namesToExport = names.length ? names : this.exportedNames |
| 651 | return new RootModule( |
| 652 | flatMorph(namesToExport, (_, name) => [ |
| 653 | name, |
| 654 | this._exports![name] |
| 655 | ]) as never |
| 656 | ) as never |
| 657 | } |
| 658 | |
| 659 | resolve<name extends exportedNameOf<$>>( |
| 660 | name: name |
nothing calls this directly
no test coverage detected
searching dependent graphs…