Function: packageRoot()
packageRoot(
packageName):string
Defined in: packages/aiui-util/src/provenance.ts:34
Absolute root directory of an installed (or workspace-linked) dependency.
Rather than resolve the package through the module system — which would hit its exports map (forcing a built dist/, and normally blocking access to package.json) — we ask Node for the node_modules dirs it would search and read package.json straight off disk. This needs nothing special from the target package (no exports entry) and works even when it has not been built, so dev iteration requires no compile step.
Parameters
packageName
string
Returns
string