Facing error in using 'connect-mongo' in the given code. Cannot read 'create' property of undefined [duplicate]
Solution 1:
Have you tried removing the default
property from your connect-mongo
import? The documentation for the connect-mongo
library seems to import MongoStore
without it.
// Your import
const MongoStore = require('connect-mongo').default
// Their import
const MongoStore = require('connect-mongo')