The code changes include: - Importing the `Image` component from `next/legacy/image` instead of `next/image` in multiple files. - Adding a new `CachedImage` component that uses the `Image` component with a custom loader. - Updating the `Logo` component to use the `CachedImage` component instead of the `img` tag. Recent user commits and repository commits do not provide additional context for the commit message.
10 lines
259 B
TypeScript
10 lines
259 B
TypeScript
import Image from "next/image";
|
|
|
|
function imageLoader({ src }: { src: string }) {
|
|
return `https://cdn.jsdelivr.net/gh/zen-browser/${src}`;
|
|
}
|
|
|
|
export default function CachedImage({ ...props }: any) {
|
|
return <Image {...props} loader={imageLoader} />;
|
|
}
|