Simplify your stack and build anything. Or everything.
Build tomorrow’s web with a modern solution you truly own.
Code-based nature means you can build on top of it to power anything.
It’s time to take back your content infrastructure.

Getting custom passport strategy to work.

default discord avatar
snackdexlast year
1

I created a custom passport strategy and everything works as intended api wise. However, when I go to the admin panel i run into: Module not found: Error: Can't resolve 'util' in '/home/node/app/node_modules/jwa'



This happens when i use jsonwebtoken import. i've tried the resolutions given in the logs but none of them work. if you've solved this issue please let me know as i'm not an expert in webpack.


I've also tried following this:

https://payloadcms.com/docs/admin/webpack#aliasing-server-only-modules

i was able to get around it by using jose instead of jsonwebtoken and jwks-rsa

  • discord user avatar
    seanzubrickas
    last year

    Hey

    @1048810654523473951

    glad you were able to get this sorted out! Feel free to open another thread if you run into anything else.

Star on GitHub

Star

Chat on Discord

Discord

online

Can't find what you're looking for?

Get dedicated engineering support directly from the Payload team.