Skip to content

feat: Expose dependency type in Node API (#614)#992

Draft
bmish wants to merge 1 commit into
mainfrom
feat/expose-dependency-type
Draft

feat: Expose dependency type in Node API (#614)#992
bmish wants to merge 1 commit into
mainfrom
feat/expose-dependency-type

Conversation

@bmish

@bmish bmish commented Jul 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Adds type to each versions[].packages entry in the Node API so callers can tell whether a usage is a dependency, devDependency, peerDependency, etc.
  • Local workspace package version entries omit type (no dependency type applies).
  • Re-exports DependencyType / DEPENDENCY_TYPE from the public package entrypoint.
  • CLI table output is unchanged.

Closes #614

Test plan

  • npm test (100% coverage)
  • npm run build
  • npm run lint (js/docs)
  • CLI against test/fixtures/testing-output — table output unchanged (exit 1 as before due to mismatches)
  • Targeted tests for dual dep types in one package and local-package entry without type

Made with Cursor

Each versions[].packages entry now includes the dependency type
(dependencies, devDependencies, etc.), omitted for local package version
records. DEPENDENCY_TYPE is re-exported from the public API.

Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Indicate what kind of dependency (dev, peer, etc) a package has on a dependency in Node API

1 participant