MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / pickedExport

Function pickedExport

src/resolution/frameworks/react.ts:504–507  ·  view source on GitHub ↗

* The component a lazy route's loader picks from the module `spec` loads: the * export named `name`, through barrels. `reads` collects the files it reads.

(spec: string, name: string, fromFile: string, context: ResolutionContext, reads?: Set<string>)

Source from the content-addressed store, hash-verified

502 * export named `name`, through barrels. `reads` collects the files it reads.
503 */
504function pickedExport(spec: string, name: string, fromFile: string, context: ResolutionContext, reads?: Set<string>): string | null {
505 const file = lazyModuleFile(spec, fromFile, context);
506 return file ? exportedComponent(file, name, context, new Set(), reads) : null;
507}
508
509/**
510 * True for a reference a React route makes: from a `route:<file>:…` node, in

Callers 5

resolveFunction · 0.85
lazyModulesFunction · 0.85
declaredComponentFunction · 0.85
lazyValueModulesFunction · 0.85
layoutComponentFunction · 0.85

Calls 2

lazyModuleFileFunction · 0.85
exportedComponentFunction · 0.85

Tested by

no test coverage detected