• ?

    user

    1 year ago
    I'm trying to use the node/nextjs middleware, but it throws an internal server error anytime the library is called:
  • r

    rp

    1 year ago
    Can you share your code please?
  • ?

    user

    1 year ago
    TypeError: Class constructor NextJS cannot be invoked without 'new'
        at __webpack_exports__.default (webpack-internal:///./pages/api/auth/[[...path]].js:56:71)
        at processTicksAndRejections (node:internal/process/task_queues:93:5)
        at async apiResolver (/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/next/dist/next-server/server/api-utils.js:8:1)
        at async DevServer.handleApiRequest (/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/next/dist/next-server/server/next-server.js:63:403)
        at async Object.fn (/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/next/dist/next-server/server/next-server.js:55:530)
        at async Router.execute (/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/next/dist/next-server/server/router.js:24:67)
        at async DevServer.run (/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/next/dist/next-server/server/next-server.js:65:1023)
        at async DevServer.handleRequest (/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/next/dist/next-server/server/next-server.js:33:450)
    warn  - ./node_modules/supertokens-auth-react/lib/build/utils.js
    Module not found: Can't resolve 'react-router' in '/Users/bjk/src/github.com/gopheracademy/supertokens-nextjs-demo/node_modules/supertokens-auth-react/lib/build'
    
    ./node_modules/supertokens-auth-react/lib/build/components/superTokensRoute.js
  • ?

    user

    1 year ago
    with my own connection URI
  • r

    rp

    1 year ago
    got it. Let me have a look
  • ?

    user

    1 year ago
    thanks!
  • ?

    user

    1 year ago
    (I checked out the "use-nextjs-helper" branch)
  • r

    rp

    1 year ago
    @User can help you out here since he made the repo
  • k

    kevin.a

    1 year ago
    Hey @bketelson let me take a look and I'll come back to you with more info