Skip to content

"Error: The Edge Function "middleware" is referencing unsupported modules: crypto" upon deployment to vercel with next-auth #45384

Closed Answered by tungvn
Tasselhat asked this question in Help
Discussion options

You must be logged in to vote

I got the same issue and found a way to fix it.

In the Project Settings > Build & Development Settings, I changed the Framework Presets from Others to Next.js and it worked perfectly.

Hope it help!

Replies: 6 comments 34 replies

Comment options

You must be logged in to vote
19 replies
@icyJoseph
Comment options

@khuezy
Comment options

@marco-digennaro
Comment options

@muke5hy
Comment options

@marco-digennaro
Comment options

Comment options

You must be logged in to vote
1 reply
@IonelLupu
Comment options

Comment options

You must be logged in to vote
2 replies
@IonelLupu
Comment options

@and3rsonsousa
Comment options

Comment options

You must be logged in to vote
10 replies
@arpit3210
Comment options

@ashishsah1000
Comment options

@maxeth
Comment options

@MahmoudEl3bady
Comment options

@sachidumaleesha
Comment options

Answer selected by Tasselhat
Comment options

You must be logged in to vote
2 replies
@ashishsah1000
Comment options

@BhandarkarPawan
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet