eugef / node-mocks-http

Mock 'http' objects for testing Express,js, Next.js and Koa routing functions
Other
755 stars 134 forks source link

Fixed index.d.ts import of mocks from express to specific dir #274

Closed Gulati21 closed 1 year ago

Gulati21 commented 1 year ago

When using npm (v16.13 or greater) and using another library that imports @types/express, the imported mocked Request, Response, and Cookie options can be polluted - leading to undesirable outcomes, especially in TS projects. Qualifying the import to be more specific resolves this issue.

Gulati21 commented 1 year ago

Hello @eugef - would it be possible for you to take a look at this some time?

eugef commented 1 year ago

Hi @Gulati21 can you explain what undesirable outcomes do you mean?

github-actions[bot] commented 1 year ago

Stale pull request message