reactjstypescriptnext.jsmantinecloudflare-pages

Image not working in production, works good on localhost


I'm building a website with Next.js and Mantine. I want to put the Image with my logo in my Header so I used Image from next/image but the problem is that it's not working when i deploy it. It works perfectly on localhost. Deployed: enter image description here

Locally: enter image description here

Code of my image that is clickable `

<Link href={"/"} >
        <Image src="https://cdn.p33t.net/ZKAVDSZEFH.png" alt='logo' width={42} height={40} />
        </Link>

` I tried using the local image but it was same. My image host is already added in the next config. I expected it to be working same as on local machine


Solution

  • I fixed it by using Image component by Mantine instead of Next