export type ResolveMapEntry = { /** * Package name. * * If the package was pulled in as a renamed non-semver dep, this will be the name specified in * the parent's dependencies (not the actual name). */ name: string; /** * Resolved/installed package version. For a linked internal package, this will end in `-linked`. * (The docs for `isExternal` explain what "internal" means.) * * If the package was pulled in as a non-semver dep, this will be the transformed version * (e.g. `0.0.0-npm-foo-1-0-0`) based on the parent's dependencies. */ version: string; /** Path to the resolved/installed package. */ path: string; /** * Map from dependency name to resolved/installed version. * * For any non-semver deps, the key (name) is as specified in package.json dependencies, * mapped to the transformed version (e.g. `0.0.0-npm-foo-1-0-0`). * * If the session (or API context) containing this resolve map was created with `skipResolveDependencies`, * this will be an empty object. With `onlyResolveDependencies`/`onlyInlinedDependencies`, it will only * contain those dependencies. */ dependencies: Record; /** * Map from requesting/parent package name `@` the actual version of that package to * the original semver range of this package that it requested. * * Example: if this entry is for package `bar`, and `foo@1.0.0` depends on `"bar": "^2.0.0"`, * this will be `{ "foo@1.0.0": "^2.0.0" }`. * * If the parent package was pulled in by its parent (the grandparent) as a non-semver dep, * the key will use the name as specified by the grandparent and the transformed version. */ requiredBy: Record<`${string}@${string}`, string>; /** * A package is considered "external" if it was installed from a package manager (its realpath * contains `node_modules`). This is the opposite of "internal", which means that the package * is defined in a local folder/repo. */ isExternal?: boolean; /** * Whether this package is linked **AND** is internal to its actual folder/repo. * (The docs for `isExternal` explain what "internal" means.) */ isLinked?: boolean; /** * Additional installed versions of this package, which are required per semver by some other * package in the map. * * For any version that was pulled in as a non-semver dep, the key will be the transformed * version (e.g. `0.0.0-npm-foo-1-0-0`). */ scopedVersions?: { [version: string]: ResolveMapEntry; }; }; //# sourceMappingURL=ResolveMapEntry.d.ts.map