<Image> not showing image on production (vercel)
Unanswered
Stephens Stock posted this in #help-forum
Stephens StockOP
I'm using Google login, google returns the users information, including the user's image url.
I use that url in the <Image src={img} ... />, but it shows a broken image icon.
Its works fine on localhost, but not when i deploy to vercel
Any idea why?
I use that url in the <Image src={img} ... />, but it shows a broken image icon.
Its works fine on localhost, but not when i deploy to vercel
Any idea why?
4 Replies
I had this happen when the case of the file name was different than what I had typed
Just something to check
Stephens StockOP
The filename is dynamic, and it works on localhost, I even printed out the variable to the screen to make sure when i run on production 🙂
It has something to do with vercel protections...
It has something to do with vercel protections...
Stephens StockOP
these settings solve the problem locally (I added it to the
next.config.js file), but when I deploy to vercel it's not taking effect.images: {
domains: ['*.googleusercontent.com'],
remotePatterns: [
{
hostname: '*.googleusercontent.com'
},
],
},