You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
'import("~/node_modules/@types/express/index").Request<import("~/node_modules/@types/express-serve-static-core/index").ParamsDictionary, any, any, qs.ParsedQs, Record<string, any>>' is not assignable to parameter of type 'import("~/@namefi/namefi-api/node_modules/@types/express-session/node_modules/@types/express-serve-static-core/index").Request<import("~/@namefi/namefi-api/node_modules/@types/express-session/node_modules/@types/express-serve-static-core/index").ParamsDictionary, any, any, qs.ParsedQs, Record...'.
The types of 'app.router' are incompatible between these types.
Type 'string' is not assignable to type 'Router'.
37 })(request, response, next);
I was able to go through all the express packages and finally found that express-session@1.18.1 is using "express": "4.17.3" exactly(no '^ | ~') and it's used as a devDependency, so I set my express version 4.17.3 and it solves the issue.
This could be avoided if the express-session uses express a peerDependency
The text was updated successfully, but these errors were encountered:
Express is only used for testing, so it doesn't make sense for it to be a peer dependency. The issue you're facing is more related to TypeScript types. Can you show which versions of types you're using?
Stack Trace
Environment information
Version:
Node.js version:
Any other relevant information:
diagnosis
I was able to go through all the express packages and finally found that express-session@1.18.1 is using
"express": "4.17.3"
exactly(no '^ | ~') and it's used as a devDependency, so I set my express version 4.17.3 and it solves the issue.This could be avoided if the express-session uses express a peerDependency
The text was updated successfully, but these errors were encountered: