Skip to content

dependency on @types/express-serve-static-core induced incompatibility #7000

Description

@alanpurple

Environment information

Version:
express 5.2.1
@types/express 5.0.6

Platform:
windows 11 x64 and ubuntu 24.04.3

Node.js version:
24.13.0

Any other relevant information:

What steps will reproduce the bug?

currently express typing have dependency
"@types/express-serve-static-core": "^5.0.0",

which installs @types/express-serve-static-core 5.1.1, which is incompatible
works up to 5.1.0

so massive same errors like this

error TS2345: Argument of type 'string | string[]' is not assignable to parameter of type 'string'.
  Type 'string[]' is not assignable to type 'string'.

80         const id = parseInt(req.params.id);

generated

and this makes the documentation on
https://expressjs.com/en/5x/api.html
useless, in that documentation, same "req.params.id" is used

@types/express-serve-static-core should be fixed

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions