I keep getting Can't resolve '@/models/Users'
on my NextJS project dashboard on Vercel when deploying changes.
But when I run pnpm run build
localy, it is successful as shown below.
I've tried deleting the node_modules
but didn't work.
It's expected to work since the file exists.
Double check that the file is actually named Users.ts
and not users.ts
as Vercel and Git are case-sensitive.
Try renaming the file to something else, commit and push, then rename it back, that resolves case-related issues.