Skip to content

build: declare @types/node only in devDependencies - #31

Open
antobinary wants to merge 1 commit into
node-24from
dedupe-types-node
Open

antobinary wants to merge 1 commit into
node-24from
dedupe-types-node

Conversation

@antobinary

Copy link
Copy Markdown
Member

What

Drops the duplicate @types/node entry from dependencies, keeping the one in
devDependencies.

Why

@types/node was declared in both sections, and the two had drifted apart
(^20.3.1 against ^20.4.4) before they were aligned in the Node 24 PR. It
supplies build-time typings only — nothing under src/ imports it at runtime
and it contributes nothing to the emitted bundle.

CI does not install with --omit=dev or NODE_ENV=production, so the typings
remain present wherever the bundle is built. npm already resolved it as a
dev-only package, so installs are unaffected; this just makes package.json say
what npm was already doing.

Testing

Against Node 24.20.0:

  • npm ci — PASS
  • npx tsc — PASS
  • npm run lint — PASS
  • npm run build-bundle — PASS

Notes for review

One line out of package.json plus the matching lock line. Depends on the Node
24 PR and should merge after it.

@types/node was listed in both dependencies and devDependencies, and the
two had drifted apart before they were aligned on ^24.13.3. It supplies
build-time typings only, so keep the devDependencies entry and drop the
duplicate.

npm already resolved it as a dev-only package, so installs are unaffected;
this just makes package.json say what npm was already doing.

@imdt-claudiop imdt-claudiop left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved.

Identical in shape to bigbluebutton/bbb-plugin-picture-in-picture#44, which is already merged: @types/node dropped from dependencies, kept in devDependencies, with the matching package-lock.json root entry removed. Nothing else changes.

Verified on Node 24.9.0 against this branch: npm install clean with no lockfile drift, npx tsc passes, npm run lint passes, and npm run build-bundle produces dist/TourPlugin.js.

Type resolution is unaffected, since devDependencies still provides @types/node ^24.13.3 and that is what the compiler picks up.

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.

2 participants