Open jderboven opened 3 months ago
I don't fully understand. Are you using an image CDN? Is the private domain an image CDN or just static images?
Actually that’s just a remote url on the customer network m not a static img
OK, can you explain exactly:
Ok what I would like is the following :
http://dpifr-stage.lovelytruc.be/sites/default/v2/lifestyle_apps_4_3_portrait/2024/04/16/node_47/113/public/2024/04/16/21088323.jpeg?itok=1713272724
What happens : the image link gets decoded and put above some srcset like a normal next image with optimization. What is rendered : nothing as it gets decoded and the link cannot be found The code :
'use client';
import { blurhashToCssGradientString } from '@unpic/placeholder';
import { Image } from '@unpic/react/nextjs';
type ImageNextProps = {
layout: 'fixed' | 'fullWidth' | 'constrained';
src: string;
alt: string;
blurHash?: string;
className?: string;
};
export const ImageNext = (props: ImageNextProps) => {
const { layout, src, alt, blurHash = 'LEHV6nWB2yk8pyo0adR*.7kCMdn4', className = '' } = props;
const placeholder = blurhashToCssGradientString(blurHash);
return (
<Image
src={src}
alt={alt}
layout={layout}
className={`image-next ${className}`}
background={placeholder}
/>
);
};
Hello,
I'm trying to use
import { Image } from '@unpic/react/nextjs';
My source comes from a private domain on my customer network, how can I disable cdn check so that my image is well displayed ? For now it comes with next/image and the url is encoded
Thanks for help